SlideShare una empresa de Scribd logo
1 de 63
Creating Knowledge out of Interlinked
             Data




LOD2 W ebinar . 29.11.2011 . Page 1           http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data




          LOD2 is a large-scale integrating project co-funded by the European
          Commission within the FP7 Information and Communication Technologies
          Work Programme. This 4-year project comprises leading Linked Open
          Data technology researchers, companies, and service providers. Coming
          from across 12 countries the partners are coordinated by the Agile
          Knowledge Engineering and Semantic Web Research Group at the
          University of Leipzig, Germany.

          LOD2 will integrate and syndicate Linked Data with existing large-scale
          applications. The project shows the benefits in the scenarios of Media and
          Publishing, Corporate Data intranets and eGovernment.




LOD2 W ebinar . 29.11.2011 . Page 2                                                    http:/ l
                                                                                             /od2.eu
Creating Knowledge out of Interlinked
             Data




          Once per month the LOD2 webinar series offer a free webinar about
          tools and services along the Linked Open Data Life Cycle.

          Stay with us and learn more about acquisition, editing, composing,
          connected applications – and finally publishing Linked Open Data.




LOD2 W ebinar . 29.11.2011 . Page 3                                            http:/ l
                                                                                     /od2.eu
Creating Knowledge out of Interlinked
             Data


Web-based Systems Group

• School of Business & Economics, Freie Universität Berlin
• Research focus: Linked Data technol
                                    ogies for extending the Worl W ide W eb with a gl
                                                               d                    obal
  data commons
• Funded Proj ects:
         •    LOD2 - Creating Knowl out of Interl
                                  edge          inked Data
         •    LATC - LOD Around The Cl ock
         •    Pl
               anetData
• Visit us at: http:/ wbsg.de
                     /




LOD2 W ebinar . 29.11.2011 . Page 4                                               http:/ l
                                                                                        /od2.eu
Creating Knowledge out of Interlinked
             Data


Main Projects

• DBpedia is a community effort l by WBSG, AKSW and OpenLink Software to:
                                ead
         •    Extract structured information from W ikipedia
         •    Make this information avail e on the W eb under an open l
                                        abl                            icense
         •    Interl the DBpedia dataset with other open datasets on the W eb
                   ink
         •    DBpedia Spotl Automatic annotation of free-text with DBpedia URIs
                            ight:


• Data Integration
         •    R2R: Transl W eb data that is represented using terms from different vocabul
                          ates                                                           aries into a singl target
                                                                                                          e
              vocabulary.
         •    Sil Toolfor generating RDF l between data items.
                k:                          inks
         •    LDIF: Transl heterogeneous Linked Data from the W eb into a cl l target representation whil
                           ates                                             ean, ocal                          e
              keeping track of data provenance.




LOD2 W ebinar . 29.11.2011 . Page 5                                                                           http:/ l
                                                                                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data


Outline

•      D2R/ Sparql in the LOD2 Stack
                 ify
•      The D2RQ Pl atform
•      The D2RQ Mapping Language
•      Exampl and Demo
               e
•      Avail ity
           abil
•      Sparql (Cl Stadl
             ify aus       er)
•      Q &A




LOD2 W ebinar . 29.11.2011 . Page 6           http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data


D2R/Sparqlify in the LOD2 Stack




LOD2 W ebinar . 29.11.2011 . Page 7           http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data


The D2RQ Platform

• System for accessing rel
                         ational databases as virtual RDF graphs
• Offers RDF-based access to the content of rel
                                              ational databases without having to repl
                                                                                     icate it
  into an RDF store

• Features:
   • query a non-RDF database using SPARQL
   • access the content of the database as Linked Data over the W eb
   • create custom dumps of the database in RDF
   • access information using the Apache Jena API




LOD2 W ebinar . 29.11.2011 . Page 8                                                    http:/ l
                                                                                             /od2.eu
Creating Knowledge out of Interlinked
             Data


Components

• The D2RQ Pl   atform consists of:
• D 2 R Q M a p p i n g L a n g u a g e , a decl              arative mapping l
                                                                              anguage for
  describing the relation between an ontol and an rel
                                         ogy           ational data model
                                                                        .
• D 2 R Q E n g i n e , uses the mappings to rewrite SQL queries against the database
  and passes query resul up to the higher l
                           ts                ayers of the frameworks
• D 2 R S e r v e r , an HTTP server that provides a Linked Data view, a HTML view
  for debugging and a SPARQL Protocol endpoint over the database.




LOD2 W ebinar . 29.11.2011 . Page 9                                                http:/ l
                                                                                         /od2.eu
Creating Knowledge out of Interlinked
             Data


Architecture




LOD2 W ebinar . 29.11.2011 . Page 10          http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data


D2RQ Mapping Language

• Decl
     arative language for mapping rel
                                    ational database schemas to RDF vocabul
                                                                          aries and
  OWL ontol ogies.
• N3 based syntax
• Very fl e
        exibl
• Usual workfl auto-generate mapping from DB schema, then customize
              ow:




LOD2 W ebinar . 29.11.2011 . Page 11                                             http:/ l
                                                                                       /od2.eu
Creating Knowledge out of Interlinked
             Data


Mapping process




LOD2 W ebinar . 29.11.2011 . Page 12          http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data


Example

• Existing database which stores information about:
        •     Conferences
        •     Papers
        •     Authors
        •     Topics
• W e want publ this database as RDF
                ish
• W e wil use the International Semantic W eb Community (ISW C) Ontol
        l                                                           ogy.




LOD2 W ebinar . 29.11.2011 . Page 13                                       http:/ l
                                                                                 /od2.eu
Creating Knowledge out of Interlinked
             Data


Define DB connection

    map:MyDatabase a d2rq:Database;
       d2rq:jdbcDSN "jdbc:mysql://localhost/mydb";
       d2rq:jdbcDriver "com.mysql.jdbc.Driver";
       d2rq:username "user";
       d2rq:password "password".

• d 2 r q : D a t a b a s e defines a JDBC connection to a l or remote rel
                                                           ocal          ational
  database
• d 2 r q : j d b c D S N specifies the JDBC database URL
        •     Typicaly of the form: jdbc:subprotocol:subname
                     l
• d 2 r q : j d b c D r i v e r specifies the JDBC driver for the database




LOD2 W ebinar . 29.11.2011 . Page 14                                         http:/ l
                                                                                   /od2.eu
Creating Knowledge out of Interlinked
             Data


Define your entities

   map:People a d2rq:ClassMap;
    d2rq:uriPattern “http://.../people/@@User.ID@@”.


                                                             (SQL fragments in red)


• d 2 r q : C l a s s M a p represents a cl or a group of simil cl
                                               ass                   ar asses
• A cl map defines how instances of the cl are identified
       ass                                 ass
• d 2 r q : u r i P a t t e r n specifies a URI pattern that wil be used to identify
                                                               l
  instances of this cl map.
                     ass




LOD2 W ebinar . 29.11.2011 . Page 15                                                   http:/ l
                                                                                             /od2.eu
Creating Knowledge out of Interlinked
             Data


Define your entities

   map:People a d2rq:ClassMap;
    d2rq:uriPattern “http://.../people/@@User.ID@@”;
    d2rq:condition “User.deleted=0”.

                                                            (SQL fragments in red)


• d 2 r q : c o n d i t i o n specifies an SQL W HERE condition
• An instance of this cl wil onl be generated for database rows that satisfy the condition
                       ass l y
• Conditions can be used to hide parts of the database from D2RQ




LOD2 W ebinar . 29.11.2011 . Page 16                                                 http:/ l
                                                                                           /od2.eu
Creating Knowledge out of Interlinked
             Data


Add properties to entities

   map:People a d2rq:ClassMap;
    d2rq:uriPattern “http://.../people/@@User.ID@@”;
    d2rq:condition “User.deleted=0”;
    d2rq:class foaf:Person .

                                       (SQL fragments in red, RDFS/OWL vocabulary in blue)


• d 2 r q : c l a s s rel the generated entity to a OWL/
                        ates                             RDFS cl
                                                               ass
• W e use the P e r s o n cl from the FOAF vocabul
                            ass                      ary




LOD2 W ebinar . 29.11.2011 . Page 17                                                     http:/ l
                                                                                               /od2.eu
Creating Knowledge out of Interlinked
             Data


Add properties to entities

    map:name a d2rq:PropertyBridge;
     d2rq:belongsToClassMap map:People;
     d2rq:property foaf:nick;
     d2rq:column “User.name”.

    map:mbox a d2rq:PropertyBridge;
     d2rq:belongsToClassMap map:People;
     d2rq:property foaf:mbox;
     d2rq:uriPattern “mailto:@@User.email@@”.
                                       (SQL fragments in red, RDFS/OWL vocabulary in blue)


•      A d 2 r q : P r o p e r t y B r i d g e rel a database col to an RDF property.
                                                    ates        umn
•      Here we use properties from the FOAF vocabul as wel
                                                  ary    l

LOD2 W ebinar . 29.11.2011 . Page 18                                                     http:/ l
                                                                                               /od2.eu
Creating Knowledge out of Interlinked
             Data


Add properties to entities

   map:mbox_sha1 a d2rq:PropertyBridge;
    d2rq:belongsToClassMap map:People;
    d2rq:property foaf:mbox_sha1sum;
    d2rq:sqlExpression
             “SHA1(CONCAT(‘mailto:’, User.email))”.
                                       (SQL fragments in red, RDFS/OWL vocabulary in blue)



• d 2 r q : s q l E x p r e s s i o n generates l   iteral val by eval
                                                             ues     uating a SQL
  expression.
• Note that querying for such a computed val might put a heavy l on the database.
                                           ue                    oad
• W e compute the SHA1 sum from the user email address


LOD2 W ebinar . 29.11.2011 . Page 19                                                         http:/ l
                                                                                                   /od2.eu
Creating Knowledge out of Interlinked
             Data


Link your entities

   map:Photos a d2rq:ClassMap;
    d2rq:uriPattern “http://.../photo/@@Photo.ID@@”;
    d2rq:class foaf:Image .
                                       (SQL fragments in red, RDFS/OWL vocabulary in blue)

• W e define a second cl mapping for photos
                        ass
• In the next step, we wil interl person with their photos
                         l      ink




LOD2 W ebinar . 29.11.2011 . Page 20                                                         http:/ l
                                                                                                   /od2.eu
Creating Knowledge out of Interlinked
             Data


Link your entities

    map:photo a d2rq:PropertyBridge;
     d2rq:belongsToClassMap map:People;
     d2rq:property foaf:made;
     d2rq:uriPattern “http://.../photo/@@Photo.UserID@@”.


                                       (SQL fragments in red, RDFS/OWL vocabulary in blue)

• W e can use the al ready presented syntax to interl persons to their photo
                                                    ink
• Photo.UserID is a foreign key to User.ID




LOD2 W ebinar . 29.11.2011 . Page 21                                                 http:/ l
                                                                                           /od2.eu
Creating Knowledge out of Interlinked
             Data


Link your entities
• Better, with l repetition:
               ess

   map:photo a d2rq:PropertyBridge;
    d2rq:belongsToClassMap map:People;
    d2rq:property foaf:made;
    d2rq:join “User.ID = Photo.UserID”;
    d2rq:refersToClassMap map:Photos .
                                       (SQL fragments in red, RDFS/OWL vocabulary in blue)




LOD2 W ebinar . 29.11.2011 . Page 22                                                 http:/ l
                                                                                           /od2.eu
Creating Knowledge out of Interlinked
             Data


Mapping Overview




LOD2 W ebinar . 29.11.2011 . Page 23          http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data




                                       • Demo


LOD2 W ebinar . 29.11.2011 . Page 24            http:/ l
                                                      /od2.eu
Creating Knowledge out of Interlinked
             Data


Availability

• D2RQ can be downl
                  oaded from the official homepage at:

                                                • http:/ d2rq.org/
                                                        /

• Support is provided through the official mail l
                                              ing ist:

                                       •   d2rq-map-devel l
                                                        @ ists.sourceforge.net

• The l
      atest source code is avail e from the proj s Git repository:
                               abl             ect'

                                           • https:/ github.com/
                                                    /           d2rq/d2rq

• D2RQ is l
          icensed under the terms of the Apache Software Licence
LOD2 W ebinar . 29.11.2011 . Page 25                                             http:/ l
                                                                                       /od2.eu
Creating Knowledge out of Interlinked
             Data


Developers




LOD2 W ebinar . 29.11.2011 . Page 26          http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data


Database Compatibility

• Supported databases
        •    Oracl e
        •    MySQL
        •    PostgreSQL
        •    SQL Server
        •    HSQLDB
        •    Interbase/Firebird
• ODBC data sources
        • Works with some l
                          imitations.
• Other databases
        • May or may not work. By defaul D2RQ interacts with the database using the SQL-92 standard.
                                       t,
          Any compatibl database should work out of the box. W e are interested in reports about D2RQ
                        e
          on other databases.


LOD2 W ebinar . 29.11.2011 . Page 27                                                           http:/ l
                                                                                                     /od2.eu
Creating Knowledge out of Interlinked
             Data


Current Work

• D2RQ is activel devel
                y     oped
• Work on supporting RDB2RDF (Direct Mapping und R2RML) in the next 6 weeks




LOD2 W ebinar . 29.11.2011 . Page 28                                          http:/ l
                                                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data




   Sparqlif
   y
                                       Project Page: http://aksw.org/projects/Sparqlify
                                       Source Code: https://github.com/AKSW/Sparqlify
LOD2 W ebinar . 29.11.2011 . Page 29                                             http:/ l
                                                                                       /od2.eu
Creating Knowledge out of Interlinked
             Data


About me


•      Cl Stadl
        aus      er
•      Austria
•      PhD Student at the University of Leipzig since 2011
         –    In the Agil Knowl Engineering and Semantic W eb (AKSW ) research group, headed by
                        e     edge
              Soeren Auer.
•      Research Interests: SpatialData Management, SPARQL-SQL query rewriting
       and optimization, Data integration.




LOD2 W ebinar . 29.11.2011 . Page 30                                                              http:/ l
                                                                                                        /od2.eu
Creating Knowledge out of Interlinked
             Data


       Agile Knowledge Engineering and
       Semantic Web Research Group

•      Founded in 2006
•      25+ Researchers
•      3 Sub groups

•      Goal
          s
         –    Contributing to the advancement of science in Semantic W eb, Knowl Engineering, Software Engineering
                                                                                 edge
         –    Cost efficient, high-impact R&D, which proves usefulness at an earl stage
                                                                                y
         –    Bridge the gap between research resul and appl
                                                      ts        ications


•      Committed to Open Source, Open Access, and Open Knowl movements
                                                           edge




LOD2 W ebinar . 29.11.2011 . Page 31                                                                                 http:/ l
                                                                                                                           /od2.eu
Creating Knowledge out of Interlinked
             Data


       Agile Knowledge Engineering and
       Semantic Web Research Group

•      EU Funded Proj
                    ects:


         –    Linked Open Data 2 (LOD2)

         –    LOD Around the Cl (LATC)
                              ock

         –    Open Data Portal (ODP)

         –    Semantic Content Management Systems for Enterprise Knowl Management and News Mining (SCMS)
                                                                     edge

         –    OntoW iki - Semantic Colaboration for Knowl Management, E-Learning and E-Tourism
                                      l                 edge




LOD2 W ebinar . 29.11.2011 . Page 32                                                                       http:/ l
                                                                                                                 /od2.eu
Creating Knowledge out of Interlinked
             Data


       Agile Knowledge Engineering and
       Semantic Web Research Group

•      Further Proj
                  ects
         –    SlideW iki
                 • Sl  ideW iki is a colaboration pl
                                        l           atform which enabl communities to buil share and pl onl presentations.
                                                                     es                  d,           ay ine
         –    LinkedGeoData
                 • Making OpenStreetMap data avail e in the Semantic W eb
                                                         abl
                 • Motivation for Sparql   ify
         –    LIMES
                 • Very fast tool for interl inking RDF knowl bases.
                                                              edge
         –    DBpedia Live
                 • Synchronization of DBpedia with W ikipedia
         –    …


•      Find more at
         –    http:/ aksw.org/ ects
                    /         Proj




LOD2 W ebinar . 29.11.2011 . Page 33                                                                                         http:/ l
                                                                                                                                   /od2.eu
Creating Knowledge out of Interlinked
             Data


Structure


•      Introduction
•      View Definition Exampl
                            e
         –    based on chalenges encountered with LinkedGeoData
                           l
•      Launching Sparql Server
                      ify
•      Demonstration
•      Initial Results of the Performance
       Evaluation
•      Concl
           usion & Future Work
•      Outro




LOD2 W ebinar . 29.11.2011 . Page 34                              http:/ l
                                                                        /od2.eu
Creating Knowledge out of Interlinked
             Data


Introduction


•      S p a r q l i f y is a SPARQL-SQL rewriter that enabl one to define RDF views on rel
                                                           es                             ational
       databases and query them with SPARQL. Currentl onl PostgreSQL is supported.
                                                    y y

•      Inputs
         –    PostgreSQL Database, Set of View Definitions, Sparql Query


•      Features
         –    Intuitive View Definition Syntax
         –    SPARQL queries are rewritten into a singl SQL query
                                                         e
                  • Give as much control as possibl to the query optimizer of the underl RDBMS
                                                       e                               ying
         –    High expressivity
                  • Language and Data type Tags can originate from col   umns
                  • Constraints can be stated for tuning the rewriting process
         –    Initial support for geospatial predicates
                  • Can be extended to enabl the use of arbitrary SQL predicates on the SPARQL l
                                                e                                              evel


LOD2 W ebinar . 29.11.2011 . Page 35                                                                  http:/ l
                                                                                                            /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “points_of_interest”

id      type                           geom
1       lgdo:Bakery                    (1, 1)
2       lgdo:School                    (2, 2)
3       lgdo:Pub                       (3, 3)




        On the following slides, Prefix Declarations are omitted for brevity



LOD2 W ebinar . 29.11.2011 . Page 36                                           http:/ l
                                                                                     /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “points_of_interest”

id      class                          geom     Create View pois As
                                                  Construct { …
1       lgdo:Bakery                    (1, 1)
2       lgdo:School                    (2, 2)
3       lgdo:Pub                       (3, 3)




LOD2 W ebinar . 29.11.2011 . Page 37                                  http:/ l
                                                                            /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “points_of_interest”

id      type                           geom     Create View pois As
                                                  Construct {
1       lgdo:Bakery                    (1, 1)
                                                    ?s a ?t .
2       lgdo:School                    (2, 2)       ?s geom:geometry ?geo .
3       lgdo:Pub                       (3, 3)     }
                                                  With …




LOD2 W ebinar . 29.11.2011 . Page 38                                          http:/ l
                                                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “points_of_interest”

id      type                           geom     Create View pois As
                                                  Construct {
1       lgdo:Bakery                    (1, 1)
                                                    ?s a ?t .
2       lgdo:School                    (2, 2)       ?s geom:geometry ?geo .
3       lgdo:Pub                       (3, 3)     }
                                                  With
                                                    ?s = spy:uri(concat(“http://ex.org/”, ?id))
                                                    ….




LOD2 W ebinar . 29.11.2011 . Page 39                                                              http:/ l
                                                                                                        /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “points_of_interest”

id      type                           geom     Create View pois As
                                                  Construct {
1       lgdo:Bakery                    (1, 1)
                                                    ?s a ?t .
2       lgdo:School                    (2, 2)       ?s geom:geometry ?geo .
3       lgdo:Pub                       (3, 3)     }
                                                  With
                                                    ?s = spy:uri(concat(“http://...”, ?id))
                                                    ?t = spy:uri(?type)
                                                    ?geom = spy:typedLiteral(?geom, ogc:WKTLiteral)
                                                  From
                                                    …




LOD2 W ebinar . 29.11.2011 . Page 40                                                       http:/ l
                                                                                                 /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “points_of_interest”

id      type                           geom     Create View pois As
                                                  Construct {
1       lgdo:Bakery                    (1, 1)
                                                    ?s a ?t .
2       lgdo:School                    (2, 2)       ?s geom:geometry ?geo .
3       lgdo:Pub                       (3, 3)     }
                                                  With
                                                    ?s = spy:uri(concat(“http://ex.org/”, ?id))
                                                    ?t = spy:uri(?type)
                                                    ?geom = spy:typedLiteral(?geom, ogc:WKTLiteral)
                                                  From
                                                    points_of_interest;




LOD2 W ebinar . 29.11.2011 . Page 41                                                       http:/ l
                                                                                                 /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “points_of_interest”

id      type                           geom     Create View pois As
                                                  Construct {
1       lgdo:Bakery                    (1, 1)
                                                    ?s a ?t .
2       lgdo:School                    (2, 2)       ?s geom:geometry ?geo .
3       lgdo:Pub                       (3, 3)     }
                                                  With
                                                    ?s = spy:uri(concat(“http://ex.org/”, ?id))
                                                    ?t = spy:uri(?type)
                                                    ?geom = spy:typedLiteral(?geom, ogc:WKTLiteral)
                                                  Constrain
                                                    ?t prefix “http://linkedgeodata.org/ontology/”
                                                  From
                                                    points_of_interest;




LOD2 W ebinar . 29.11.2011 . Page 42                                                       http:/ l
                                                                                                 /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “resource_label”

resource                  label        language
lgdo:Bakery               Baeckerei    de
lgdo:Bakery               Bakery       en
lgdo:School               Schule       de




LOD2 W ebinar . 29.11.2011 . Page 43              http:/ l
                                                        /od2.eu
Creating Knowledge out of Interlinked
             Data


        View Definition Example: Mapping
        the table “resource_label”

resource                  label        language
lgdo:Bakery               Baeckerei    de
lgdo:Bakery               Bakery       en
lgdo:School               Schule       de
                                            Create View labels As
                                              Construct {
                                                ?s rdfs:label ?l .
                                              }
                                              With
                                                ?s = spy:uri(?resource)
                                                ?l = spy:plainLiteral(?label, ?language)
                                              Constrain
                                                ?s prefix “http://linkedgeodata.org/ontology/”
                                              From
                                                resource_labels;
LOD2 W ebinar . 29.11.2011 . Page 44                                                    http:/ l
                                                                                              /od2.eu
Creating Knowledge out of Interlinked
             Data


       View Definition Example: Adding a
       set of static triples




                                       Create View static_triples As
                                         Construct {
                                            lgdo:Bakery a owl:Class .
                                            lgdo:School a owl:Class .
                                            lgdo:Pub a owl:class
                                         };




LOD2 W ebinar . 29.11.2011 . Page 45                                    http:/ l
                                                                              /od2.eu
Creating Knowledge out of Interlinked
             Data


View Definition File Syntax


        Prefix Declarations

        Create View {name} As
            Construct {
                {triple patterns}
            }
            With
                {variable bindings}
            Constrain
                {constraint expressions}
            From
                logical table (table, view or SQL query);

        … More View Definitions …



LOD2 W ebinar . 29.11.2011 . Page 46                        http:/ l
                                                                  /od2.eu
Creating Knowledge out of Interlinked
             Data


                       View Definition Example:
Create View
                       Wortschatz
                     view_co_n As
    Construct {
        ?a wso:coOccursDirectlyWith ?b .
        ?x owl:annotatedSource ?a .
        ?x owl:annotatedProperty wso:coOccursDirectlyWith .
        ?x owl:annotatedTarget ?b .
        ?x wso:frequency ?f .
        ?x wso:sigma ?s .
    }
    With
        ?a = spy:uri(concat('http://aksw.org/wortschatz/word/', ?w1_id))
        ?b = spy:uri(concat('http://aksw.org/wortschatz/word/', ?w2_id))
        ?x = spy:uri(concat('http://aksw.org/wortschatz/co-occurence/direct/',
                                                          ?w1_id, '/', ?w2_id))
        ?f = spy:typedLiteral(?freq, xsd:long)
        ?s = spy:typedLiteral(?sig, xsd:long)
    From
        [[SELECT w1_id, w2_id, freq::bigint, sig::bigint FROM co_n]];


                                       Escape SQL queries in double brackets


LOD2 W ebinar . 29.11.2011 . Page 47                                           http:/ l
                                                                                     /od2.eu
Creating Knowledge out of Interlinked
             Data


Launching Sparqlify


•      Downl from git, buil with
           oad            d
         –    mvn assebl
                       y:assembl
                               y
•      Run
         –    j -cp target/
              ava          sparql
                                ify-0.0.1-SNAPSHOT-j
                                                   ar-with-dependencies.j RunEndpoint [options]
                                                                         ar
•      Options are
         –    Server Configuration
                • -c            Config fil containing the mapping definitions
                                         e
                • -P            Server port [defaul 7
                                                    t 531]
         –    Database settings
                • -h            Hostname of the database (e.g. l host or l host:5432)
                                                                ocal          ocal
                • -d            Database name
                • -u            User name
                • -p            Password
         –    Qual of Service
                  ity
                • -n            Maximum resul set size
                                                 t
                • -t            Maximum query execution time (excl    uding rewriting time)


LOD2 W ebinar . 29.11.2011 . Page 48                                                              http:/ l
                                                                                                        /od2.eu
Creating Knowledge out of Interlinked
             Data




                                       Demonstration




LOD2 W ebinar . 29.11.2011 . Page 49                   http:/ l
                                                             /od2.eu
Creating Knowledge out of Interlinked
             Data


                        Initial Results of the
                        Performance Evaluation

•      Initialperformance comparision on BSBM 1 mio dataset on PostgreSQL:
         –    (Times per Query Mix)
         –    D2R Fast Mode Disabl ~8sec
                                    ed:
         –    D2R Fast Mode Enabl ~3sec
                                   ed:
         –    Sparql 4 sec
                    ify:
         –    Performance is comparabl to D2R.
                                       e


•      Mixed resul for the LinkedGeoData schema:
                 ts
         –    Simpl queries work wel on the LGD schema
                  e                l
         –    Compl queries are troubl
                   ex                 esome (timeouts) on a compl OSM dump as the PostgreSQL optimizer makes suboptimal choices.
                                                                ete




LOD2 W ebinar . 29.11.2011 . Page 50                                                                                  http:/ l
                                                                                                                            /od2.eu
Creating Knowledge out of Interlinked
             Data


Conclusion and Future Work


•      Sparql provides an intuitive Mapping Syntax
            ify

•      Originaly devel
               l     oped for the LinkedGeoData use-case
         –    Spatial predicate support, arbitrary predicate support pl
                                                                      anned.
         –    URIs, l
                    anguage and datatype tags can be mapped from col    umns of the DB.
         –    Queries are rewritten into a singl SQL statement, in order to give as much control to the query optimizer of the underl
                                                e                                                                                   ying
              DBMS as possibl   e.


•      Initialperformance resul seem to be comparabl to D2R
                              ts                   e
         –    More extensive testing has yet to be done


•      Bugfixing

•      Additionalfeatures
         –    Especialy support for the COUNT keyword
                      l

LOD2 W ebinar . 29.11.2011 . Page 51                                                                                              http:/ l
                                                                                                                                        /od2.eu
Creating Knowledge out of Interlinked
             Data


Contact


•      Proj Page
          ect
         –    http:/ aksw.org/ ects/
                    /         proj Sparql
                                        ify


•      Source Code
         –    https:/ github.com/
                     /           AKSW /Sparql
                                            ify


•      AKSW Research Group
         –    http:/ aksw.org
                    /


•      My Work Page
         –    http:/ bis.informatik.uni-l
                    /                   eipzig.de/ ausStadl
                                                  Cl      er


•      My Email
         –    cstadl informatik.uni-l
                   er@              eipzig.de


LOD2 W ebinar . 29.11.2011 . Page 52                           http:/ l
                                                                     /od2.eu
Creating Knowledge out of Interlinked
             Data




           Thank you for your attention!

                                       Q &A


LOD2 W ebinar . 29.11.2011 . Page 53          http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data




Credits

Jingle       R.E.M., Martin Kaltenböck, Florian Kondert
Coordination Thomas Thurner
             Martin Kaltenböck
Moderation   Martin Kaltenböck
Presented by Robert Isele & Claus Stadler




LOD2 W ebinar . 29.11.2011 . Page 54                      http:/ l
                                                                /od2.eu
Creating Knowledge out of Interlinked
             Data




          Hope you enjoyed staying with us – if you need more detailed
          information, visit us at www.lod2.eu and let us know how we can
          improve to meet your expectations!

          Don’t forget to register for our next webinar

           22.05. 2012 – Cloud View (Exalead Dassault Systems, France)
           19.06. 2012 – PoolParty Thesaurus Manager (SWC, Austria)
          Have a great day and don’t forget ...




                                                                            http:/ l
                                                                                  /od2.eu
LOD2 W ebinar . 29.11.2011 . Page 55                                         http:/ l
                                                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data




                                             http:/ l
                                                   /od2.eu
LOD2 W ebinar . 29.11.2011 . Page 56          http:/ l
                                                     /od2.eu
Creating Knowledge out of Interlinked
             Data


                     Why another SPARQL – SQL
                     Rewriter?

•      There is
         –    Virtuoso RDF Views
         –    D2R
         –    Revel Spyder
                   ytix
         –    Asio Semantic W eb Bridge for Relational Databases
         –    ODE Mapster, RDBToOnto
         –    Soon further impl
                              ementations of R2RML
         –    Ultrawrap
         –    …




LOD2 W ebinar . 29.11.2011 . Page 57                               http:/ l
                                                                         /od2.eu
Creating Knowledge out of Interlinked
             Data


Motivation

•      Map OpenStreetMap data to RDF
         –    Taken approach
                • Downl a OSM pl fil (> 10GB compressed), pipe each OSM entity (node, way, rel
                          oad           anet e                                                               ation) through a custom Java
                    RDF mapper, and l the data into Virtuoso
                                      oad
                • Impl  emented a LiveSync on top of that
                • Repeat the dump process after each change in the mappings
                • Takes more than 2 days.
         –    Goal
                • Immediate effect of a change in the mappings
                • Reuse of Osmosis' LiveSync
         –    Possibl Sol
                    e ution
                • Keep the mapping information in the rel  ationaldatabase, and use a RDB-RDF mapper for querying it.
         –    However: Back in April 2011, none of the existing RDB-RDF sol  utions seemed suitable
                • Lack of support for spatial predicates
                • Eval  uations of Sparql ters in memory
                                         -Fil
                • No support for creating l s where the l
                                             iteral             anguage tag or datatype are stored in the database.




LOD2 W ebinar . 29.11.2011 . Page 58                                                                                            http:/ l
                                                                                                                                      /od2.eu
Creating Knowledge out of Interlinked
             Data


Motivation


•      LinkedGeoData proj Convert OpenStreetMap (OSM) data as RDF
                        ect:
         –    (http:/ l
                     /inkedgeodata.org)


•      Main tabl of the OSM Schema (Excerpt):
               es
         –    Nodes(id, geom, tstamp)
         –    NodeTags(node_id, k, v)
                                                            (place, city)
                                                            (name, Leipzig)
         –    Ways(id, geom, tstamp)
         –    WayTags(way_id, k, v)

         –    WayNodes(way_id, sequence_id, node_id)




LOD2 W ebinar . 29.11.2011 . Page 59                                          http:/ l
                                                                                    /od2.eu
Creating Knowledge out of Interlinked
                 Data


           Challenges with OpenStreetMap
           data
    •     Geometry datatype
    •     URIs and l
                   anguage tags stored in database tabl
                                                      es

Nodes (OSM)
node_id            k                   v
1                  amenity             school

Additional mappings tables for LGD

                                                k          v             property     object
        lgd_map_resource_kv
                                                amenity    school        rdf:type     lgdo:school

                                                k          v             label        language
lgd_map_resource_labels
                                                amenity    school        Schule       de
                                                               Labels imported from TranslateWiki
    LOD2 W ebinar . 29.11.2011 . Page 60                                                   http:/ l
                                                                                                 /od2.eu
Creating Knowledge out of Interlinked
             Data


Rewriting process




LOD2 W ebinar . 29.11.2011 . Page 61          http:/ l
                                                    /od2.eu
Creating Knowledge out of Interlinked
             Data


Rewriting process


•      Rewriting process
         –    View Candidate Finding
                • Given a SPARQL query, find an appropriate subset of the views for answering the query
         –    Rewriting
                • After the candidates have been identified, transl the SPARQL al
                                                                  ate              gebra to SQL algebra.
                • Thereby do book-keeping of how the SPARQL variabl are reconstructed from the SQL col
                                                                      es                                  umns.
         –    Resul Set Rendering
                  t
                • Execute the SQL query, construct the RDF according to the SPARQL variabl bindings, serial the resul
                                                                                            e             ize       t.




LOD2 W ebinar . 29.11.2011 . Page 62                                                                                     http:/ l
                                                                                                                               /od2.eu
Creating Knowledge out of Interlinked
             Data


View Candidate Finding



•      Based on
         Le, Wangchao and Duan, Songyun and Kementsietsidis, Anastasios and Li, Feifei and Wang, Min
         R e w r it in g Q u e r ie s o n S P A R Q L V ie w s ,
         In WWW 2011




LOD2 W ebinar . 29.11.2011 . Page 63                                                                   http:/ l
                                                                                                             /od2.eu

Más contenido relacionado

La actualidad más candente

Soren Auer - LOD2 - creating knowledge out of Interlinked Data
Soren Auer - LOD2 - creating knowledge out of Interlinked DataSoren Auer - LOD2 - creating knowledge out of Interlinked Data
Soren Auer - LOD2 - creating knowledge out of Interlinked DataOpen City Foundation
 
Setting up Dataverse repository for research data
Setting up Dataverse repository for research dataSetting up Dataverse repository for research data
Setting up Dataverse repository for research datavty
 
The world of Docker and Kubernetes
The world of Docker and Kubernetes The world of Docker and Kubernetes
The world of Docker and Kubernetes vty
 
Clariah Tech Day: Controlled Vocabularies and Ontologies in Dataverse
Clariah Tech Day: Controlled Vocabularies and Ontologies in DataverseClariah Tech Day: Controlled Vocabularies and Ontologies in Dataverse
Clariah Tech Day: Controlled Vocabularies and Ontologies in Dataversevty
 
Technical integration of data repositories status and challenges
Technical integration of data repositories status and challengesTechnical integration of data repositories status and challenges
Technical integration of data repositories status and challengesvty
 
CLARIN CMDI support in Dataverse
CLARIN CMDI support in Dataverse CLARIN CMDI support in Dataverse
CLARIN CMDI support in Dataverse vty
 
External controlled vocabularies support in Dataverse
External controlled vocabularies support in DataverseExternal controlled vocabularies support in Dataverse
External controlled vocabularies support in Dataversevty
 
Building COVID-19 Museum as Open Science Project
Building COVID-19 Museum as Open Science ProjectBuilding COVID-19 Museum as Open Science Project
Building COVID-19 Museum as Open Science Projectvty
 
Integration of WORSICA’s thematic service in EOSC, Service QA and Dataverse
Integration of WORSICA’s thematic service in EOSC,  Service QA and DataverseIntegration of WORSICA’s thematic service in EOSC,  Service QA and Dataverse
Integration of WORSICA’s thematic service in EOSC, Service QA and Dataversevty
 
Semantic web-and-public-data - en
Semantic web-and-public-data - enSemantic web-and-public-data - en
Semantic web-and-public-data - enTenforce
 
Introduction to the Data Web, DBpedia and the Life-cycle of Linked Data
Introduction to the Data Web, DBpedia and the Life-cycle of Linked DataIntroduction to the Data Web, DBpedia and the Life-cycle of Linked Data
Introduction to the Data Web, DBpedia and the Life-cycle of Linked DataSören Auer
 
Flexible metadata schemes for research data repositories - Clarin Conference...
Flexible metadata schemes for research data repositories  - Clarin Conference...Flexible metadata schemes for research data repositories  - Clarin Conference...
Flexible metadata schemes for research data repositories - Clarin Conference...Vyacheslav Tykhonov
 
Controlled vocabularies and ontologies in Dataverse data repository
Controlled vocabularies and ontologies in Dataverse data repositoryControlled vocabularies and ontologies in Dataverse data repository
Controlled vocabularies and ontologies in Dataverse data repositoryvty
 
Industry Ontologies: Case Studies in Creating and Extending Schema.org
Industry Ontologies: Case Studies in Creating and Extending Schema.org Industry Ontologies: Case Studies in Creating and Extending Schema.org
Industry Ontologies: Case Studies in Creating and Extending Schema.org sopekmir
 

La actualidad más candente (20)

LOD2 Webinar Series: Zemanta / Open refine
LOD2 Webinar Series: Zemanta / Open refine LOD2 Webinar Series: Zemanta / Open refine
LOD2 Webinar Series: Zemanta / Open refine
 
Soren Auer - LOD2 - creating knowledge out of Interlinked Data
Soren Auer - LOD2 - creating knowledge out of Interlinked DataSoren Auer - LOD2 - creating knowledge out of Interlinked Data
Soren Auer - LOD2 - creating knowledge out of Interlinked Data
 
Free Webinar: LOD2 Stack - 1st release
Free Webinar: LOD2 Stack - 1st releaseFree Webinar: LOD2 Stack - 1st release
Free Webinar: LOD2 Stack - 1st release
 
Lod2
Lod2Lod2
Lod2
 
LOD2: State of Play WP3A - Knowledge Base Creation, Enrichment and Repair
LOD2: State of Play WP3A - Knowledge Base Creation, Enrichment and RepairLOD2: State of Play WP3A - Knowledge Base Creation, Enrichment and Repair
LOD2: State of Play WP3A - Knowledge Base Creation, Enrichment and Repair
 
Setting up Dataverse repository for research data
Setting up Dataverse repository for research dataSetting up Dataverse repository for research data
Setting up Dataverse repository for research data
 
LOD2: State of Play WP1: Requirements, Design & LOD2 Stack Prototype
LOD2: State of Play WP1: Requirements, Design & LOD2 Stack PrototypeLOD2: State of Play WP1: Requirements, Design & LOD2 Stack Prototype
LOD2: State of Play WP1: Requirements, Design & LOD2 Stack Prototype
 
The world of Docker and Kubernetes
The world of Docker and Kubernetes The world of Docker and Kubernetes
The world of Docker and Kubernetes
 
LOD2 webinar series: Virtuoso by OpenLink Software
LOD2 webinar series: Virtuoso by OpenLink SoftwareLOD2 webinar series: Virtuoso by OpenLink Software
LOD2 webinar series: Virtuoso by OpenLink Software
 
Clariah Tech Day: Controlled Vocabularies and Ontologies in Dataverse
Clariah Tech Day: Controlled Vocabularies and Ontologies in DataverseClariah Tech Day: Controlled Vocabularies and Ontologies in Dataverse
Clariah Tech Day: Controlled Vocabularies and Ontologies in Dataverse
 
Technical integration of data repositories status and challenges
Technical integration of data repositories status and challengesTechnical integration of data repositories status and challenges
Technical integration of data repositories status and challenges
 
CLARIN CMDI support in Dataverse
CLARIN CMDI support in Dataverse CLARIN CMDI support in Dataverse
CLARIN CMDI support in Dataverse
 
External controlled vocabularies support in Dataverse
External controlled vocabularies support in DataverseExternal controlled vocabularies support in Dataverse
External controlled vocabularies support in Dataverse
 
Building COVID-19 Museum as Open Science Project
Building COVID-19 Museum as Open Science ProjectBuilding COVID-19 Museum as Open Science Project
Building COVID-19 Museum as Open Science Project
 
Integration of WORSICA’s thematic service in EOSC, Service QA and Dataverse
Integration of WORSICA’s thematic service in EOSC,  Service QA and DataverseIntegration of WORSICA’s thematic service in EOSC,  Service QA and Dataverse
Integration of WORSICA’s thematic service in EOSC, Service QA and Dataverse
 
Semantic web-and-public-data - en
Semantic web-and-public-data - enSemantic web-and-public-data - en
Semantic web-and-public-data - en
 
Introduction to the Data Web, DBpedia and the Life-cycle of Linked Data
Introduction to the Data Web, DBpedia and the Life-cycle of Linked DataIntroduction to the Data Web, DBpedia and the Life-cycle of Linked Data
Introduction to the Data Web, DBpedia and the Life-cycle of Linked Data
 
Flexible metadata schemes for research data repositories - Clarin Conference...
Flexible metadata schemes for research data repositories  - Clarin Conference...Flexible metadata schemes for research data repositories  - Clarin Conference...
Flexible metadata schemes for research data repositories - Clarin Conference...
 
Controlled vocabularies and ontologies in Dataverse data repository
Controlled vocabularies and ontologies in Dataverse data repositoryControlled vocabularies and ontologies in Dataverse data repository
Controlled vocabularies and ontologies in Dataverse data repository
 
Industry Ontologies: Case Studies in Creating and Extending Schema.org
Industry Ontologies: Case Studies in Creating and Extending Schema.org Industry Ontologies: Case Studies in Creating and Extending Schema.org
Industry Ontologies: Case Studies in Creating and Extending Schema.org
 

Similar a LOD2 Webinar Series: D2R and Sparqlify

OntoWiki Application Framework & Erfurt API
OntoWiki Application Framework & Erfurt APIOntoWiki Application Framework & Erfurt API
OntoWiki Application Framework & Erfurt APIPhilipp Frischmuth
 
LOD2 Webinar Series - 7 - CloudView
LOD2 Webinar Series - 7 - CloudView LOD2 Webinar Series - 7 - CloudView
LOD2 Webinar Series - 7 - CloudView Semantic Web Company
 
W4 4 marc-alexandre-nolin-v2
W4 4 marc-alexandre-nolin-v2W4 4 marc-alexandre-nolin-v2
W4 4 marc-alexandre-nolin-v2nolmar01
 
Linked data and semantic wikis
Linked data and semantic wikisLinked data and semantic wikis
Linked data and semantic wikisSören Auer
 
The web of interlinked data and knowledge stripped
The web of interlinked data and knowledge strippedThe web of interlinked data and knowledge stripped
The web of interlinked data and knowledge strippedSören Auer
 
Linked Data in Linguistics for NLP and Web Annotation
Linked Data in Linguistics for NLP and Web AnnotationLinked Data in Linguistics for NLP and Web Annotation
Linked Data in Linguistics for NLP and Web AnnotationSebastian Hellmann
 
Vila LOD-innovacion- bib-semweb-redux
Vila LOD-innovacion- bib-semweb-reduxVila LOD-innovacion- bib-semweb-redux
Vila LOD-innovacion- bib-semweb-reduxLIS EPI Meeting
 
Linked Data for the Masses: The approach and the Software
Linked Data for the Masses: The approach and the SoftwareLinked Data for the Masses: The approach and the Software
Linked Data for the Masses: The approach and the SoftwareIMC Technologies
 
Link Sets And Why They Are Important (EDF2012)
Link Sets And Why They Are Important (EDF2012)Link Sets And Why They Are Important (EDF2012)
Link Sets And Why They Are Important (EDF2012)Anja Jentzsch
 
Building a Knowledge Graph using NLP and Ontologies
Building a Knowledge Graph using NLP and OntologiesBuilding a Knowledge Graph using NLP and Ontologies
Building a Knowledge Graph using NLP and OntologiesNeo4j
 
Contributing to the Smart City Through Linked Library Data
Contributing to the Smart City Through Linked Library DataContributing to the Smart City Through Linked Library Data
Contributing to the Smart City Through Linked Library DataMarcia Zeng
 
What is New in W3C land?
What is New in W3C land?What is New in W3C land?
What is New in W3C land?Ivan Herman
 

Similar a LOD2 Webinar Series: D2R and Sparqlify (20)

LOD2 Webinar Series: SILK
LOD2 Webinar Series: SILKLOD2 Webinar Series: SILK
LOD2 Webinar Series: SILK
 
LOD2: State of Play WP3B - Knowledge Extraction, NLP2RDF + NIF
LOD2: State of Play WP3B - Knowledge Extraction, NLP2RDF + NIFLOD2: State of Play WP3B - Knowledge Extraction, NLP2RDF + NIF
LOD2: State of Play WP3B - Knowledge Extraction, NLP2RDF + NIF
 
OntoWiki Application Framework & Erfurt API
OntoWiki Application Framework & Erfurt APIOntoWiki Application Framework & Erfurt API
OntoWiki Application Framework & Erfurt API
 
LOD2: State of Play WP5 - Linked Data Visualization, Browsing and Authoring
LOD2: State of Play WP5 - Linked Data Visualization, Browsing and AuthoringLOD2: State of Play WP5 - Linked Data Visualization, Browsing and Authoring
LOD2: State of Play WP5 - Linked Data Visualization, Browsing and Authoring
 
NIF - NLP Interchange Format
NIF - NLP Interchange FormatNIF - NLP Interchange Format
NIF - NLP Interchange Format
 
Lod2
Lod2Lod2
Lod2
 
LOD2 Webinar Series - 7 - CloudView
LOD2 Webinar Series - 7 - CloudView LOD2 Webinar Series - 7 - CloudView
LOD2 Webinar Series - 7 - CloudView
 
W4 4 marc-alexandre-nolin-v2
W4 4 marc-alexandre-nolin-v2W4 4 marc-alexandre-nolin-v2
W4 4 marc-alexandre-nolin-v2
 
LOD2 Webinar Series: LIMES
LOD2 Webinar Series: LIMESLOD2 Webinar Series: LIMES
LOD2 Webinar Series: LIMES
 
Limes webinar
Limes webinarLimes webinar
Limes webinar
 
Linked data and semantic wikis
Linked data and semantic wikisLinked data and semantic wikis
Linked data and semantic wikis
 
The web of interlinked data and knowledge stripped
The web of interlinked data and knowledge strippedThe web of interlinked data and knowledge stripped
The web of interlinked data and knowledge stripped
 
Linked Data in Linguistics for NLP and Web Annotation
Linked Data in Linguistics for NLP and Web AnnotationLinked Data in Linguistics for NLP and Web Annotation
Linked Data in Linguistics for NLP and Web Annotation
 
Vila LOD-innovacion- bib-semweb-redux
Vila LOD-innovacion- bib-semweb-reduxVila LOD-innovacion- bib-semweb-redux
Vila LOD-innovacion- bib-semweb-redux
 
Linked Data for the Masses: The approach and the Software
Linked Data for the Masses: The approach and the SoftwareLinked Data for the Masses: The approach and the Software
Linked Data for the Masses: The approach and the Software
 
Link Sets And Why They Are Important (EDF2012)
Link Sets And Why They Are Important (EDF2012)Link Sets And Why They Are Important (EDF2012)
Link Sets And Why They Are Important (EDF2012)
 
LOD2 Webinar Series: LOD2 in information and publishing industry
LOD2 Webinar Series: LOD2 in information and publishing industryLOD2 Webinar Series: LOD2 in information and publishing industry
LOD2 Webinar Series: LOD2 in information and publishing industry
 
Building a Knowledge Graph using NLP and Ontologies
Building a Knowledge Graph using NLP and OntologiesBuilding a Knowledge Graph using NLP and Ontologies
Building a Knowledge Graph using NLP and Ontologies
 
Contributing to the Smart City Through Linked Library Data
Contributing to the Smart City Through Linked Library DataContributing to the Smart City Through Linked Library Data
Contributing to the Smart City Through Linked Library Data
 
What is New in W3C land?
What is New in W3C land?What is New in W3C land?
What is New in W3C land?
 

Más de LOD2 Creating Knowledge out of Interlinked Data

Más de LOD2 Creating Knowledge out of Interlinked Data (17)

LOD2 Webinar Series: Virtuoso 7
LOD2 Webinar Series: Virtuoso 7LOD2 Webinar Series: Virtuoso 7
LOD2 Webinar Series: Virtuoso 7
 
LOD2 Webinar Series: DBpedia Spotlight
LOD2 Webinar Series: DBpedia SpotlightLOD2 Webinar Series: DBpedia Spotlight
LOD2 Webinar Series: DBpedia Spotlight
 
LOD2 Webinar Series: publicdata.eu and CKAN
LOD2 Webinar Series: publicdata.eu and CKANLOD2 Webinar Series: publicdata.eu and CKAN
LOD2 Webinar Series: publicdata.eu and CKAN
 
LOD2 General Presentation 2012
LOD2 General Presentation 2012LOD2 General Presentation 2012
LOD2 General Presentation 2012
 
LOD2 Webinar Series: PoolParty
LOD2 Webinar Series: PoolPartyLOD2 Webinar Series: PoolParty
LOD2 Webinar Series: PoolParty
 
LOD2 Plenary Vienna 2012: WP12 - Project Management
LOD2 Plenary Vienna 2012: WP12 - Project ManagementLOD2 Plenary Vienna 2012: WP12 - Project Management
LOD2 Plenary Vienna 2012: WP12 - Project Management
 
LOD2 Plenary Vienna 2012: WP10 - Training, Dissemination, Community Building,...
LOD2 Plenary Vienna 2012: WP10 - Training, Dissemination, Community Building,...LOD2 Plenary Vienna 2012: WP10 - Training, Dissemination, Community Building,...
LOD2 Plenary Vienna 2012: WP10 - Training, Dissemination, Community Building,...
 
LOD2 Plenary Vienna 2012: WP9A - LOD for a Distributed Marketplace for Public...
LOD2 Plenary Vienna 2012: WP9A - LOD for a Distributed Marketplace for Public...LOD2 Plenary Vienna 2012: WP9A - LOD for a Distributed Marketplace for Public...
LOD2 Plenary Vienna 2012: WP9A - LOD for a Distributed Marketplace for Public...
 
LOD2 Plenary Vienna 2012: WP9 publicdata.eu – Publishing Governmental Informa...
LOD2 Plenary Vienna 2012: WP9 publicdata.eu – Publishing Governmental Informa...LOD2 Plenary Vienna 2012: WP9 publicdata.eu – Publishing Governmental Informa...
LOD2 Plenary Vienna 2012: WP9 publicdata.eu – Publishing Governmental Informa...
 
LOD2 Plenary Vienna 2012: WP8: Linked Open Data for Enterprise Data Web
LOD2 Plenary Vienna 2012: WP8: Linked Open Data for Enterprise Data WebLOD2 Plenary Vienna 2012: WP8: Linked Open Data for Enterprise Data Web
LOD2 Plenary Vienna 2012: WP8: Linked Open Data for Enterprise Data Web
 
LOD2 Plenary Vienna 2012: WP7 - Linked Open Data for Media and Publishing
LOD2 Plenary Vienna 2012: WP7 - Linked Open Data for Media and Publishing LOD2 Plenary Vienna 2012: WP7 - Linked Open Data for Media and Publishing
LOD2 Plenary Vienna 2012: WP7 - Linked Open Data for Media and Publishing
 
LOD2 Plenary Vienna 2012: WP6 - Interfaces, Integration & LOD2 Stack
LOD2 Plenary Vienna 2012: WP6 - Interfaces, Integration & LOD2 StackLOD2 Plenary Vienna 2012: WP6 - Interfaces, Integration & LOD2 Stack
LOD2 Plenary Vienna 2012: WP6 - Interfaces, Integration & LOD2 Stack
 
LOD2 Plenary Vienna 2012: WP5 - Linked Data Browsing, Visualization and Autho...
LOD2 Plenary Vienna 2012: WP5 - Linked Data Browsing, Visualization and Autho...LOD2 Plenary Vienna 2012: WP5 - Linked Data Browsing, Visualization and Autho...
LOD2 Plenary Vienna 2012: WP5 - Linked Data Browsing, Visualization and Autho...
 
LOD2 Plenary Vienna 2012: WP4 - Reuse, Interlinking and Knowledge Fusion
LOD2 Plenary Vienna 2012: WP4 - Reuse, Interlinking and Knowledge FusionLOD2 Plenary Vienna 2012: WP4 - Reuse, Interlinking and Knowledge Fusion
LOD2 Plenary Vienna 2012: WP4 - Reuse, Interlinking and Knowledge Fusion
 
LOD2 Plenary Vienna 2012: WP2 - Storing and Querying Very Large Knowledge Bases
LOD2 Plenary Vienna 2012: WP2 - Storing and Querying Very Large Knowledge BasesLOD2 Plenary Vienna 2012: WP2 - Storing and Querying Very Large Knowledge Bases
LOD2 Plenary Vienna 2012: WP2 - Storing and Querying Very Large Knowledge Bases
 
LOD2 Webinar Series: OntoWiki
LOD2 Webinar Series: OntoWikiLOD2 Webinar Series: OntoWiki
LOD2 Webinar Series: OntoWiki
 
LOD2 Plenary Meeting 2011: Institute Mihajlo Pupin – Partner Introduction
LOD2 Plenary Meeting 2011: Institute Mihajlo Pupin – Partner IntroductionLOD2 Plenary Meeting 2011: Institute Mihajlo Pupin – Partner Introduction
LOD2 Plenary Meeting 2011: Institute Mihajlo Pupin – Partner Introduction
 

Último

"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusZilliz
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 

Último (20)

"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 

LOD2 Webinar Series: D2R and Sparqlify

  • 1. Creating Knowledge out of Interlinked Data LOD2 W ebinar . 29.11.2011 . Page 1 http:/ l /od2.eu
  • 2. Creating Knowledge out of Interlinked Data LOD2 is a large-scale integrating project co-funded by the European Commission within the FP7 Information and Communication Technologies Work Programme. This 4-year project comprises leading Linked Open Data technology researchers, companies, and service providers. Coming from across 12 countries the partners are coordinated by the Agile Knowledge Engineering and Semantic Web Research Group at the University of Leipzig, Germany. LOD2 will integrate and syndicate Linked Data with existing large-scale applications. The project shows the benefits in the scenarios of Media and Publishing, Corporate Data intranets and eGovernment. LOD2 W ebinar . 29.11.2011 . Page 2 http:/ l /od2.eu
  • 3. Creating Knowledge out of Interlinked Data Once per month the LOD2 webinar series offer a free webinar about tools and services along the Linked Open Data Life Cycle. Stay with us and learn more about acquisition, editing, composing, connected applications – and finally publishing Linked Open Data. LOD2 W ebinar . 29.11.2011 . Page 3 http:/ l /od2.eu
  • 4. Creating Knowledge out of Interlinked Data Web-based Systems Group • School of Business & Economics, Freie Universität Berlin • Research focus: Linked Data technol ogies for extending the Worl W ide W eb with a gl d obal data commons • Funded Proj ects: • LOD2 - Creating Knowl out of Interl edge inked Data • LATC - LOD Around The Cl ock • Pl anetData • Visit us at: http:/ wbsg.de / LOD2 W ebinar . 29.11.2011 . Page 4 http:/ l /od2.eu
  • 5. Creating Knowledge out of Interlinked Data Main Projects • DBpedia is a community effort l by WBSG, AKSW and OpenLink Software to: ead • Extract structured information from W ikipedia • Make this information avail e on the W eb under an open l abl icense • Interl the DBpedia dataset with other open datasets on the W eb ink • DBpedia Spotl Automatic annotation of free-text with DBpedia URIs ight: • Data Integration • R2R: Transl W eb data that is represented using terms from different vocabul ates aries into a singl target e vocabulary. • Sil Toolfor generating RDF l between data items. k: inks • LDIF: Transl heterogeneous Linked Data from the W eb into a cl l target representation whil ates ean, ocal e keeping track of data provenance. LOD2 W ebinar . 29.11.2011 . Page 5 http:/ l /od2.eu
  • 6. Creating Knowledge out of Interlinked Data Outline • D2R/ Sparql in the LOD2 Stack ify • The D2RQ Pl atform • The D2RQ Mapping Language • Exampl and Demo e • Avail ity abil • Sparql (Cl Stadl ify aus er) • Q &A LOD2 W ebinar . 29.11.2011 . Page 6 http:/ l /od2.eu
  • 7. Creating Knowledge out of Interlinked Data D2R/Sparqlify in the LOD2 Stack LOD2 W ebinar . 29.11.2011 . Page 7 http:/ l /od2.eu
  • 8. Creating Knowledge out of Interlinked Data The D2RQ Platform • System for accessing rel ational databases as virtual RDF graphs • Offers RDF-based access to the content of rel ational databases without having to repl icate it into an RDF store • Features: • query a non-RDF database using SPARQL • access the content of the database as Linked Data over the W eb • create custom dumps of the database in RDF • access information using the Apache Jena API LOD2 W ebinar . 29.11.2011 . Page 8 http:/ l /od2.eu
  • 9. Creating Knowledge out of Interlinked Data Components • The D2RQ Pl atform consists of: • D 2 R Q M a p p i n g L a n g u a g e , a decl arative mapping l anguage for describing the relation between an ontol and an rel ogy ational data model . • D 2 R Q E n g i n e , uses the mappings to rewrite SQL queries against the database and passes query resul up to the higher l ts ayers of the frameworks • D 2 R S e r v e r , an HTTP server that provides a Linked Data view, a HTML view for debugging and a SPARQL Protocol endpoint over the database. LOD2 W ebinar . 29.11.2011 . Page 9 http:/ l /od2.eu
  • 10. Creating Knowledge out of Interlinked Data Architecture LOD2 W ebinar . 29.11.2011 . Page 10 http:/ l /od2.eu
  • 11. Creating Knowledge out of Interlinked Data D2RQ Mapping Language • Decl arative language for mapping rel ational database schemas to RDF vocabul aries and OWL ontol ogies. • N3 based syntax • Very fl e exibl • Usual workfl auto-generate mapping from DB schema, then customize ow: LOD2 W ebinar . 29.11.2011 . Page 11 http:/ l /od2.eu
  • 12. Creating Knowledge out of Interlinked Data Mapping process LOD2 W ebinar . 29.11.2011 . Page 12 http:/ l /od2.eu
  • 13. Creating Knowledge out of Interlinked Data Example • Existing database which stores information about: • Conferences • Papers • Authors • Topics • W e want publ this database as RDF ish • W e wil use the International Semantic W eb Community (ISW C) Ontol l ogy. LOD2 W ebinar . 29.11.2011 . Page 13 http:/ l /od2.eu
  • 14. Creating Knowledge out of Interlinked Data Define DB connection map:MyDatabase a d2rq:Database; d2rq:jdbcDSN "jdbc:mysql://localhost/mydb"; d2rq:jdbcDriver "com.mysql.jdbc.Driver"; d2rq:username "user"; d2rq:password "password". • d 2 r q : D a t a b a s e defines a JDBC connection to a l or remote rel ocal ational database • d 2 r q : j d b c D S N specifies the JDBC database URL • Typicaly of the form: jdbc:subprotocol:subname l • d 2 r q : j d b c D r i v e r specifies the JDBC driver for the database LOD2 W ebinar . 29.11.2011 . Page 14 http:/ l /od2.eu
  • 15. Creating Knowledge out of Interlinked Data Define your entities map:People a d2rq:ClassMap; d2rq:uriPattern “http://.../people/@@User.ID@@”. (SQL fragments in red) • d 2 r q : C l a s s M a p represents a cl or a group of simil cl ass ar asses • A cl map defines how instances of the cl are identified ass ass • d 2 r q : u r i P a t t e r n specifies a URI pattern that wil be used to identify l instances of this cl map. ass LOD2 W ebinar . 29.11.2011 . Page 15 http:/ l /od2.eu
  • 16. Creating Knowledge out of Interlinked Data Define your entities map:People a d2rq:ClassMap; d2rq:uriPattern “http://.../people/@@User.ID@@”; d2rq:condition “User.deleted=0”. (SQL fragments in red) • d 2 r q : c o n d i t i o n specifies an SQL W HERE condition • An instance of this cl wil onl be generated for database rows that satisfy the condition ass l y • Conditions can be used to hide parts of the database from D2RQ LOD2 W ebinar . 29.11.2011 . Page 16 http:/ l /od2.eu
  • 17. Creating Knowledge out of Interlinked Data Add properties to entities map:People a d2rq:ClassMap; d2rq:uriPattern “http://.../people/@@User.ID@@”; d2rq:condition “User.deleted=0”; d2rq:class foaf:Person . (SQL fragments in red, RDFS/OWL vocabulary in blue) • d 2 r q : c l a s s rel the generated entity to a OWL/ ates RDFS cl ass • W e use the P e r s o n cl from the FOAF vocabul ass ary LOD2 W ebinar . 29.11.2011 . Page 17 http:/ l /od2.eu
  • 18. Creating Knowledge out of Interlinked Data Add properties to entities map:name a d2rq:PropertyBridge; d2rq:belongsToClassMap map:People; d2rq:property foaf:nick; d2rq:column “User.name”. map:mbox a d2rq:PropertyBridge; d2rq:belongsToClassMap map:People; d2rq:property foaf:mbox; d2rq:uriPattern “mailto:@@User.email@@”. (SQL fragments in red, RDFS/OWL vocabulary in blue) • A d 2 r q : P r o p e r t y B r i d g e rel a database col to an RDF property. ates umn • Here we use properties from the FOAF vocabul as wel ary l LOD2 W ebinar . 29.11.2011 . Page 18 http:/ l /od2.eu
  • 19. Creating Knowledge out of Interlinked Data Add properties to entities map:mbox_sha1 a d2rq:PropertyBridge; d2rq:belongsToClassMap map:People; d2rq:property foaf:mbox_sha1sum; d2rq:sqlExpression “SHA1(CONCAT(‘mailto:’, User.email))”. (SQL fragments in red, RDFS/OWL vocabulary in blue) • d 2 r q : s q l E x p r e s s i o n generates l iteral val by eval ues uating a SQL expression. • Note that querying for such a computed val might put a heavy l on the database. ue oad • W e compute the SHA1 sum from the user email address LOD2 W ebinar . 29.11.2011 . Page 19 http:/ l /od2.eu
  • 20. Creating Knowledge out of Interlinked Data Link your entities map:Photos a d2rq:ClassMap; d2rq:uriPattern “http://.../photo/@@Photo.ID@@”; d2rq:class foaf:Image . (SQL fragments in red, RDFS/OWL vocabulary in blue) • W e define a second cl mapping for photos ass • In the next step, we wil interl person with their photos l ink LOD2 W ebinar . 29.11.2011 . Page 20 http:/ l /od2.eu
  • 21. Creating Knowledge out of Interlinked Data Link your entities map:photo a d2rq:PropertyBridge; d2rq:belongsToClassMap map:People; d2rq:property foaf:made; d2rq:uriPattern “http://.../photo/@@Photo.UserID@@”. (SQL fragments in red, RDFS/OWL vocabulary in blue) • W e can use the al ready presented syntax to interl persons to their photo ink • Photo.UserID is a foreign key to User.ID LOD2 W ebinar . 29.11.2011 . Page 21 http:/ l /od2.eu
  • 22. Creating Knowledge out of Interlinked Data Link your entities • Better, with l repetition: ess map:photo a d2rq:PropertyBridge; d2rq:belongsToClassMap map:People; d2rq:property foaf:made; d2rq:join “User.ID = Photo.UserID”; d2rq:refersToClassMap map:Photos . (SQL fragments in red, RDFS/OWL vocabulary in blue) LOD2 W ebinar . 29.11.2011 . Page 22 http:/ l /od2.eu
  • 23. Creating Knowledge out of Interlinked Data Mapping Overview LOD2 W ebinar . 29.11.2011 . Page 23 http:/ l /od2.eu
  • 24. Creating Knowledge out of Interlinked Data • Demo LOD2 W ebinar . 29.11.2011 . Page 24 http:/ l /od2.eu
  • 25. Creating Knowledge out of Interlinked Data Availability • D2RQ can be downl oaded from the official homepage at: • http:/ d2rq.org/ / • Support is provided through the official mail l ing ist: • d2rq-map-devel l @ ists.sourceforge.net • The l atest source code is avail e from the proj s Git repository: abl ect' • https:/ github.com/ / d2rq/d2rq • D2RQ is l icensed under the terms of the Apache Software Licence LOD2 W ebinar . 29.11.2011 . Page 25 http:/ l /od2.eu
  • 26. Creating Knowledge out of Interlinked Data Developers LOD2 W ebinar . 29.11.2011 . Page 26 http:/ l /od2.eu
  • 27. Creating Knowledge out of Interlinked Data Database Compatibility • Supported databases • Oracl e • MySQL • PostgreSQL • SQL Server • HSQLDB • Interbase/Firebird • ODBC data sources • Works with some l imitations. • Other databases • May or may not work. By defaul D2RQ interacts with the database using the SQL-92 standard. t, Any compatibl database should work out of the box. W e are interested in reports about D2RQ e on other databases. LOD2 W ebinar . 29.11.2011 . Page 27 http:/ l /od2.eu
  • 28. Creating Knowledge out of Interlinked Data Current Work • D2RQ is activel devel y oped • Work on supporting RDB2RDF (Direct Mapping und R2RML) in the next 6 weeks LOD2 W ebinar . 29.11.2011 . Page 28 http:/ l /od2.eu
  • 29. Creating Knowledge out of Interlinked Data Sparqlif y Project Page: http://aksw.org/projects/Sparqlify Source Code: https://github.com/AKSW/Sparqlify LOD2 W ebinar . 29.11.2011 . Page 29 http:/ l /od2.eu
  • 30. Creating Knowledge out of Interlinked Data About me • Cl Stadl aus er • Austria • PhD Student at the University of Leipzig since 2011 – In the Agil Knowl Engineering and Semantic W eb (AKSW ) research group, headed by e edge Soeren Auer. • Research Interests: SpatialData Management, SPARQL-SQL query rewriting and optimization, Data integration. LOD2 W ebinar . 29.11.2011 . Page 30 http:/ l /od2.eu
  • 31. Creating Knowledge out of Interlinked Data Agile Knowledge Engineering and Semantic Web Research Group • Founded in 2006 • 25+ Researchers • 3 Sub groups • Goal s – Contributing to the advancement of science in Semantic W eb, Knowl Engineering, Software Engineering edge – Cost efficient, high-impact R&D, which proves usefulness at an earl stage y – Bridge the gap between research resul and appl ts ications • Committed to Open Source, Open Access, and Open Knowl movements edge LOD2 W ebinar . 29.11.2011 . Page 31 http:/ l /od2.eu
  • 32. Creating Knowledge out of Interlinked Data Agile Knowledge Engineering and Semantic Web Research Group • EU Funded Proj ects: – Linked Open Data 2 (LOD2) – LOD Around the Cl (LATC) ock – Open Data Portal (ODP) – Semantic Content Management Systems for Enterprise Knowl Management and News Mining (SCMS) edge – OntoW iki - Semantic Colaboration for Knowl Management, E-Learning and E-Tourism l edge LOD2 W ebinar . 29.11.2011 . Page 32 http:/ l /od2.eu
  • 33. Creating Knowledge out of Interlinked Data Agile Knowledge Engineering and Semantic Web Research Group • Further Proj ects – SlideW iki • Sl ideW iki is a colaboration pl l atform which enabl communities to buil share and pl onl presentations. es d, ay ine – LinkedGeoData • Making OpenStreetMap data avail e in the Semantic W eb abl • Motivation for Sparql ify – LIMES • Very fast tool for interl inking RDF knowl bases. edge – DBpedia Live • Synchronization of DBpedia with W ikipedia – … • Find more at – http:/ aksw.org/ ects / Proj LOD2 W ebinar . 29.11.2011 . Page 33 http:/ l /od2.eu
  • 34. Creating Knowledge out of Interlinked Data Structure • Introduction • View Definition Exampl e – based on chalenges encountered with LinkedGeoData l • Launching Sparql Server ify • Demonstration • Initial Results of the Performance Evaluation • Concl usion & Future Work • Outro LOD2 W ebinar . 29.11.2011 . Page 34 http:/ l /od2.eu
  • 35. Creating Knowledge out of Interlinked Data Introduction • S p a r q l i f y is a SPARQL-SQL rewriter that enabl one to define RDF views on rel es ational databases and query them with SPARQL. Currentl onl PostgreSQL is supported. y y • Inputs – PostgreSQL Database, Set of View Definitions, Sparql Query • Features – Intuitive View Definition Syntax – SPARQL queries are rewritten into a singl SQL query e • Give as much control as possibl to the query optimizer of the underl RDBMS e ying – High expressivity • Language and Data type Tags can originate from col umns • Constraints can be stated for tuning the rewriting process – Initial support for geospatial predicates • Can be extended to enabl the use of arbitrary SQL predicates on the SPARQL l e evel LOD2 W ebinar . 29.11.2011 . Page 35 http:/ l /od2.eu
  • 36. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “points_of_interest” id type geom 1 lgdo:Bakery (1, 1) 2 lgdo:School (2, 2) 3 lgdo:Pub (3, 3) On the following slides, Prefix Declarations are omitted for brevity LOD2 W ebinar . 29.11.2011 . Page 36 http:/ l /od2.eu
  • 37. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “points_of_interest” id class geom Create View pois As Construct { … 1 lgdo:Bakery (1, 1) 2 lgdo:School (2, 2) 3 lgdo:Pub (3, 3) LOD2 W ebinar . 29.11.2011 . Page 37 http:/ l /od2.eu
  • 38. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “points_of_interest” id type geom Create View pois As Construct { 1 lgdo:Bakery (1, 1) ?s a ?t . 2 lgdo:School (2, 2) ?s geom:geometry ?geo . 3 lgdo:Pub (3, 3) } With … LOD2 W ebinar . 29.11.2011 . Page 38 http:/ l /od2.eu
  • 39. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “points_of_interest” id type geom Create View pois As Construct { 1 lgdo:Bakery (1, 1) ?s a ?t . 2 lgdo:School (2, 2) ?s geom:geometry ?geo . 3 lgdo:Pub (3, 3) } With ?s = spy:uri(concat(“http://ex.org/”, ?id)) …. LOD2 W ebinar . 29.11.2011 . Page 39 http:/ l /od2.eu
  • 40. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “points_of_interest” id type geom Create View pois As Construct { 1 lgdo:Bakery (1, 1) ?s a ?t . 2 lgdo:School (2, 2) ?s geom:geometry ?geo . 3 lgdo:Pub (3, 3) } With ?s = spy:uri(concat(“http://...”, ?id)) ?t = spy:uri(?type) ?geom = spy:typedLiteral(?geom, ogc:WKTLiteral) From … LOD2 W ebinar . 29.11.2011 . Page 40 http:/ l /od2.eu
  • 41. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “points_of_interest” id type geom Create View pois As Construct { 1 lgdo:Bakery (1, 1) ?s a ?t . 2 lgdo:School (2, 2) ?s geom:geometry ?geo . 3 lgdo:Pub (3, 3) } With ?s = spy:uri(concat(“http://ex.org/”, ?id)) ?t = spy:uri(?type) ?geom = spy:typedLiteral(?geom, ogc:WKTLiteral) From points_of_interest; LOD2 W ebinar . 29.11.2011 . Page 41 http:/ l /od2.eu
  • 42. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “points_of_interest” id type geom Create View pois As Construct { 1 lgdo:Bakery (1, 1) ?s a ?t . 2 lgdo:School (2, 2) ?s geom:geometry ?geo . 3 lgdo:Pub (3, 3) } With ?s = spy:uri(concat(“http://ex.org/”, ?id)) ?t = spy:uri(?type) ?geom = spy:typedLiteral(?geom, ogc:WKTLiteral) Constrain ?t prefix “http://linkedgeodata.org/ontology/” From points_of_interest; LOD2 W ebinar . 29.11.2011 . Page 42 http:/ l /od2.eu
  • 43. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “resource_label” resource label language lgdo:Bakery Baeckerei de lgdo:Bakery Bakery en lgdo:School Schule de LOD2 W ebinar . 29.11.2011 . Page 43 http:/ l /od2.eu
  • 44. Creating Knowledge out of Interlinked Data View Definition Example: Mapping the table “resource_label” resource label language lgdo:Bakery Baeckerei de lgdo:Bakery Bakery en lgdo:School Schule de Create View labels As Construct { ?s rdfs:label ?l . } With ?s = spy:uri(?resource) ?l = spy:plainLiteral(?label, ?language) Constrain ?s prefix “http://linkedgeodata.org/ontology/” From resource_labels; LOD2 W ebinar . 29.11.2011 . Page 44 http:/ l /od2.eu
  • 45. Creating Knowledge out of Interlinked Data View Definition Example: Adding a set of static triples Create View static_triples As Construct { lgdo:Bakery a owl:Class . lgdo:School a owl:Class . lgdo:Pub a owl:class }; LOD2 W ebinar . 29.11.2011 . Page 45 http:/ l /od2.eu
  • 46. Creating Knowledge out of Interlinked Data View Definition File Syntax Prefix Declarations Create View {name} As Construct { {triple patterns} } With {variable bindings} Constrain {constraint expressions} From logical table (table, view or SQL query); … More View Definitions … LOD2 W ebinar . 29.11.2011 . Page 46 http:/ l /od2.eu
  • 47. Creating Knowledge out of Interlinked Data View Definition Example: Create View Wortschatz view_co_n As Construct { ?a wso:coOccursDirectlyWith ?b . ?x owl:annotatedSource ?a . ?x owl:annotatedProperty wso:coOccursDirectlyWith . ?x owl:annotatedTarget ?b . ?x wso:frequency ?f . ?x wso:sigma ?s . } With ?a = spy:uri(concat('http://aksw.org/wortschatz/word/', ?w1_id)) ?b = spy:uri(concat('http://aksw.org/wortschatz/word/', ?w2_id)) ?x = spy:uri(concat('http://aksw.org/wortschatz/co-occurence/direct/', ?w1_id, '/', ?w2_id)) ?f = spy:typedLiteral(?freq, xsd:long) ?s = spy:typedLiteral(?sig, xsd:long) From [[SELECT w1_id, w2_id, freq::bigint, sig::bigint FROM co_n]]; Escape SQL queries in double brackets LOD2 W ebinar . 29.11.2011 . Page 47 http:/ l /od2.eu
  • 48. Creating Knowledge out of Interlinked Data Launching Sparqlify • Downl from git, buil with oad d – mvn assebl y:assembl y • Run – j -cp target/ ava sparql ify-0.0.1-SNAPSHOT-j ar-with-dependencies.j RunEndpoint [options] ar • Options are – Server Configuration • -c Config fil containing the mapping definitions e • -P Server port [defaul 7 t 531] – Database settings • -h Hostname of the database (e.g. l host or l host:5432) ocal ocal • -d Database name • -u User name • -p Password – Qual of Service ity • -n Maximum resul set size t • -t Maximum query execution time (excl uding rewriting time) LOD2 W ebinar . 29.11.2011 . Page 48 http:/ l /od2.eu
  • 49. Creating Knowledge out of Interlinked Data Demonstration LOD2 W ebinar . 29.11.2011 . Page 49 http:/ l /od2.eu
  • 50. Creating Knowledge out of Interlinked Data Initial Results of the Performance Evaluation • Initialperformance comparision on BSBM 1 mio dataset on PostgreSQL: – (Times per Query Mix) – D2R Fast Mode Disabl ~8sec ed: – D2R Fast Mode Enabl ~3sec ed: – Sparql 4 sec ify: – Performance is comparabl to D2R. e • Mixed resul for the LinkedGeoData schema: ts – Simpl queries work wel on the LGD schema e l – Compl queries are troubl ex esome (timeouts) on a compl OSM dump as the PostgreSQL optimizer makes suboptimal choices. ete LOD2 W ebinar . 29.11.2011 . Page 50 http:/ l /od2.eu
  • 51. Creating Knowledge out of Interlinked Data Conclusion and Future Work • Sparql provides an intuitive Mapping Syntax ify • Originaly devel l oped for the LinkedGeoData use-case – Spatial predicate support, arbitrary predicate support pl anned. – URIs, l anguage and datatype tags can be mapped from col umns of the DB. – Queries are rewritten into a singl SQL statement, in order to give as much control to the query optimizer of the underl e ying DBMS as possibl e. • Initialperformance resul seem to be comparabl to D2R ts e – More extensive testing has yet to be done • Bugfixing • Additionalfeatures – Especialy support for the COUNT keyword l LOD2 W ebinar . 29.11.2011 . Page 51 http:/ l /od2.eu
  • 52. Creating Knowledge out of Interlinked Data Contact • Proj Page ect – http:/ aksw.org/ ects/ / proj Sparql ify • Source Code – https:/ github.com/ / AKSW /Sparql ify • AKSW Research Group – http:/ aksw.org / • My Work Page – http:/ bis.informatik.uni-l / eipzig.de/ ausStadl Cl er • My Email – cstadl informatik.uni-l er@ eipzig.de LOD2 W ebinar . 29.11.2011 . Page 52 http:/ l /od2.eu
  • 53. Creating Knowledge out of Interlinked Data Thank you for your attention! Q &A LOD2 W ebinar . 29.11.2011 . Page 53 http:/ l /od2.eu
  • 54. Creating Knowledge out of Interlinked Data Credits Jingle R.E.M., Martin Kaltenböck, Florian Kondert Coordination Thomas Thurner Martin Kaltenböck Moderation Martin Kaltenböck Presented by Robert Isele & Claus Stadler LOD2 W ebinar . 29.11.2011 . Page 54 http:/ l /od2.eu
  • 55. Creating Knowledge out of Interlinked Data Hope you enjoyed staying with us – if you need more detailed information, visit us at www.lod2.eu and let us know how we can improve to meet your expectations! Don’t forget to register for our next webinar 22.05. 2012 – Cloud View (Exalead Dassault Systems, France) 19.06. 2012 – PoolParty Thesaurus Manager (SWC, Austria) Have a great day and don’t forget ... http:/ l /od2.eu LOD2 W ebinar . 29.11.2011 . Page 55 http:/ l /od2.eu
  • 56. Creating Knowledge out of Interlinked Data http:/ l /od2.eu LOD2 W ebinar . 29.11.2011 . Page 56 http:/ l /od2.eu
  • 57. Creating Knowledge out of Interlinked Data Why another SPARQL – SQL Rewriter? • There is – Virtuoso RDF Views – D2R – Revel Spyder ytix – Asio Semantic W eb Bridge for Relational Databases – ODE Mapster, RDBToOnto – Soon further impl ementations of R2RML – Ultrawrap – … LOD2 W ebinar . 29.11.2011 . Page 57 http:/ l /od2.eu
  • 58. Creating Knowledge out of Interlinked Data Motivation • Map OpenStreetMap data to RDF – Taken approach • Downl a OSM pl fil (> 10GB compressed), pipe each OSM entity (node, way, rel oad anet e ation) through a custom Java RDF mapper, and l the data into Virtuoso oad • Impl emented a LiveSync on top of that • Repeat the dump process after each change in the mappings • Takes more than 2 days. – Goal • Immediate effect of a change in the mappings • Reuse of Osmosis' LiveSync – Possibl Sol e ution • Keep the mapping information in the rel ationaldatabase, and use a RDB-RDF mapper for querying it. – However: Back in April 2011, none of the existing RDB-RDF sol utions seemed suitable • Lack of support for spatial predicates • Eval uations of Sparql ters in memory -Fil • No support for creating l s where the l iteral anguage tag or datatype are stored in the database. LOD2 W ebinar . 29.11.2011 . Page 58 http:/ l /od2.eu
  • 59. Creating Knowledge out of Interlinked Data Motivation • LinkedGeoData proj Convert OpenStreetMap (OSM) data as RDF ect: – (http:/ l /inkedgeodata.org) • Main tabl of the OSM Schema (Excerpt): es – Nodes(id, geom, tstamp) – NodeTags(node_id, k, v) (place, city) (name, Leipzig) – Ways(id, geom, tstamp) – WayTags(way_id, k, v) – WayNodes(way_id, sequence_id, node_id) LOD2 W ebinar . 29.11.2011 . Page 59 http:/ l /od2.eu
  • 60. Creating Knowledge out of Interlinked Data Challenges with OpenStreetMap data • Geometry datatype • URIs and l anguage tags stored in database tabl es Nodes (OSM) node_id k v 1 amenity school Additional mappings tables for LGD k v property object lgd_map_resource_kv amenity school rdf:type lgdo:school k v label language lgd_map_resource_labels amenity school Schule de Labels imported from TranslateWiki LOD2 W ebinar . 29.11.2011 . Page 60 http:/ l /od2.eu
  • 61. Creating Knowledge out of Interlinked Data Rewriting process LOD2 W ebinar . 29.11.2011 . Page 61 http:/ l /od2.eu
  • 62. Creating Knowledge out of Interlinked Data Rewriting process • Rewriting process – View Candidate Finding • Given a SPARQL query, find an appropriate subset of the views for answering the query – Rewriting • After the candidates have been identified, transl the SPARQL al ate gebra to SQL algebra. • Thereby do book-keeping of how the SPARQL variabl are reconstructed from the SQL col es umns. – Resul Set Rendering t • Execute the SQL query, construct the RDF according to the SPARQL variabl bindings, serial the resul e ize t. LOD2 W ebinar . 29.11.2011 . Page 62 http:/ l /od2.eu
  • 63. Creating Knowledge out of Interlinked Data View Candidate Finding • Based on Le, Wangchao and Duan, Songyun and Kementsietsidis, Anastasios and Li, Feifei and Wang, Min R e w r it in g Q u e r ie s o n S P A R Q L V ie w s , In WWW 2011 LOD2 W ebinar . 29.11.2011 . Page 63 http:/ l /od2.eu