Your SlideShare is downloading. ×
0
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
What;s Coming In SPARQL2?
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

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

What;s Coming In SPARQL2?

4,806

Published on

A brief introduction to SPARQL and the current status of SPARQL 2, as presented to the NYC Semantic Web group on October 1, 2009.

A brief introduction to SPARQL and the current status of SPARQL 2, as presented to the NYC Semantic Web group on October 1, 2009.

Published in: Technology, Business
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
4,806
On Slideshare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
107
Comments
0
Likes
2
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • http://www.w3.org/Submission/SPARQL-Update/
  • http://www.w3.org/Submission/SPARQL-Update/
  • http://www.w3.org/Submission/SPARQL-Update/
  • Transcript

    • 1. What’s coming with SPARQL 2?<br />Slides available online at:<br />http://www.slideshare.net/LeeFeigenbaum/whats-coming-in-sparql2<br />Comments & questions to:<br />Lee Feigenbaum &lt;lee@cambridgesemantics.com&gt;<br />VP Technology & Standards, Cambridge Semantics<br />Co-chair, W3C SPARQL Working Group<br />
    • 2. For More Details<br />SPARQL By Example<br />http://www.cambridgesemantics.com/2008/09/sparql-by-example/<br />SPARQL Cheat Sheet<br />http://www.slideshare.net/LeeFeigenbaum/sparql-cheat-sheet<br />SPARQL2 Status<br />http://www.slideshare.net/LeeFeigenbaum/sparql2-status<br />
    • 3. Why SPARQL?<br />SPARQL is the query language of the Semantic Web. SPARQL lets us:<br />Pull values from structured and semi-structured data<br />Explore data by querying unknown relationships<br />Perform complex joins of disparate data sources in a single, simple query<br />Transform RDF data from one vocabulary to another<br />
    • 4. Structure of a SPARQL Query<br />A SPARQL query comprises, in order:<br />Prefix declarations, for abbreviating URIs<br />Dataset definition, stating what RDF graph(s) are being queried<br />A result clause, identifying what information to return from the query<br />The query pattern, specifying what to query for in the underlying dataset<br />Query modifiers, slicing, ordering, and otherwise rearranging query results<br />
    • 5. Anatomy of a SPARQL Query<br />PREFIXfoo:&lt;…&gt;<br />PREFIXbar:&lt;…&gt;<br />…<br />SELECT …<br />FROM &lt;…&gt;<br />FROM NAMED &lt;…&gt;<br />WHERE{<br /> …<br />}<br />ORDER BY …<br />LIMIT …<br />OFFSET …<br />Declare prefix<br />shortcuts <br />(optional)<br />Query result <br />clause<br />Define the <br />dataset (optional)<br />Query pattern<br />Query modifiers<br />(optional)<br />
    • 6. An Example SPARQL Query<br />Find the name of all landlocked countries with a population bigger than 15 million<br />PREFIXrdfs:&lt;http://www.w3.org/2000/01/rdf-schema#&gt;<br />PREFIXtype:&lt;http://dbpedia.org/class/yago/&gt;<br />PREFIXprop: &lt;http://dbpedia.org/property/&gt;<br />SELECT?country_name ?population <br />WHERE{ <br />?countryatype:LandlockedCountries;<br />rdfs:label?country_name;<br />prop:populationEstimate?population.<br />FILTER(?population&gt;15000000).<br />}<br />
    • 7. SPARQL Over HTTP (the SPARQL Protocol)<br />http://host.domain.com/sparql/endpoint?&lt;parameters&gt;<br />where &lt;parameters&gt;can include:<br />query=&lt;encoded query string&gt;<br />e.g. SELECT+*%0DWHERE+{…<br />default-graph-uri=&lt;encoded graph URI&gt;<br />e.g. http%3A%2F%2Fexmaple.com%2Ffoo…<br />n.b. zero of more occurrences of default-graph-uri<br /> named-graph-uri=&lt;encoded graph URI&gt;<br />e.g. http%3A%2F%2Fexmaple.com%2Fbar…<br />n.b. zero of more occurrences of named-graph-uri<br />HTTP GET or POST. Graphs given in the protocol override graphs given in the query.<br />
    • 8. Some Public SPARQL Endpoints<br />
    • 9. Disclaimer<br />The SPARQL Working Group has not yet decided many of the technical questions surveyed in these slides. All examples are subject to change; please do not construe them as indicators or endorsements of specific technical designs/decisions.<br />All opinions are Lee Feigenbaum’s alone.<br />
    • 10. Naming<br />I use “SPARQL2” to collectively refer to the work of the 2nd SPARQL Working Group. The actual languages being worked on are known as:SPARQL/Query 1.1SPARQL/Update 1.0<br />
    • 11. Where are we now?<br />Today<br />August 2010<br />March 2009<br />???<br />Last Call and beyond of core SPARQL specifications<br />July 2009<br />FPWD of SPARQL New Features and Rationales document<br />October 2009<br />FPWD of core SPARQL specifications<br />
    • 12. Overview<br />
    • 13. Projected Expressions<br />Select expressions other than variables (literals, functions on literals and variables, etc.)<br />Issues around:<br />Do expressions require an aliased name?<br />Syntax (main issue here)<br />SELECT ?price * ?qty AS ?total_price<br />WHERE {<br /> …<br />}<br />
    • 14. Aggregates<br />À la SQL aggregates (MIN, MAX, COUNT, AVG, etc.)<br />Issues around:<br />Which aggregates to include<br />Aggregates over mixed datatypes<br />Syntax, keywords, custom aggregates<br />SELECT MIN(?price) AS ?min_price …<br />WHERE { … }<br />GROUP BY ?item<br />
    • 15. Subqueries<br />Nested queries allow multiple queries to be combined into one. <br />Issues around:<br />Variable scope & evaluation model<br />Precise syntax<br />SELECT ?article ?authorWHERE { ?article ex:author ?author . { SELECT ?article WHERE { … ?article … } ORDER BY … LIMIT … }}<br />
    • 16. Negation<br />Supplant the mystifying OPTIONAL/!bound method of negation with a dedicated construct<br />Issues around:<br />Filter semantics vs. set-difference semantics<br />Choice of keyword(s)<br />SELECT … WHERE { ?person a foaf:Person .<br /> NOT { <br /> ?person foaf:mbox ?email<br /> }<br />}<br />
    • 17. Service Description<br />A standard discovery mechanism and vocabulary for describing the capabilities, extensions, data sets, and more for a SPARQL endpoint<br />Discovery. How can a client find the RDF that describes a SPARQL endpoint at a particular URI?<br />Description. What predicates, classes, values, etc. should a client expect to find (and be able to query) once it locates a service description?<br />Issues around:<br />Choice of discovery mechanism<br /> Which predicates and enumerations to define URIs for<br />
    • 18. Update Language<br />Based on the SPARQL Update member submission<br />Batch insert & delete<br />Insert & delete based on triple patterns<br />Graph management (creation, removal)<br />Issues around:<br />Graph stores vs. triple stores<br />Which language statements to include?<br />Transactions/atomicity/concurrency?<br />
    • 19. Update Protocol<br />The ability to issue SPARQL/Update language statements via a standard protocol (e.g. via HTTP POST)<br />Issues around:<br />Relation to existing SPARQL (Query) Protocol<br /> Security<br /> Need for WSDL description? SOAP bindings?<br />
    • 20. RESTful Update<br />Where appropriate, map RESTful HTTP requests to SPARQL/Update operations<br />DELETE /foo/g1 …-&gt; DELETE DATA FROM ex:g1 …<br />Issues around:<br />Which mappings to include?<br />Updating graphs with URIs that are not under the control of the SPARQL endpoint<br />
    • 21. Property Paths<br />Support arbitrary-length predicate paths in triple patterns – “regular expressions” on predicates?<br />Query hierarchical structures such as RDF collections<br />Issues around:<br />Can variables be used in path expressions?<br />Can the length of a path be found?<br />Are paths first-class datatypes?<br />SELECT … WHERE { ?person foaf:knows+ ?network .<br />}<br />
    • 22. Basic Federated Query<br />Initial scaffolding for authoring federated SPARQL queries<br />Likely will involve a keyword to explicitly target portions of a query to specific endpoints<br />Initial plan: Start with ARQ’s SERVICE keyword<br />SELECT … WHERE { … SERVICE ex:books {<br /> …<br /> }<br />}<br />
    • 23. Entailment Regime Semantics<br />SPARQL/Query 1.0 defines a mechanism to extend SPARQL semantics for additional entailment regimes<br />Use this mechanism to define the semantics of SPARQL queries for:<br />RDF Schema<br />OWL flavors<br />RIF rule sets<br />…<br />Issues around:<br />Requiring consistency checks<br />How to limit infinite results (e.g. from axiomatic inferences)<br />
    • 24. Common Functions<br />Extend the set of functions that SPARQL engines must support to include some of…<br />Common string functions (e.g. substr)<br />Common date/time/datetime functions<br />Logical functions (COALESCE, IF, …?)<br />Limited discussion to date about which functions to include<br />
    • 25. Get Involved<br />Join. <br />Email team-sparql-chairs@w3.org<br />Follow. <br />WG materials at http://www.w3.org/2009/sparql/wiki/<br />Comment. <br />Public feedback at public-rdf-dawg-comments@w3.org<br />Use. <br />Discuss SPARQL at public-sparql-dev@w3.org<br />
    • 26. SPARQL Resources<br />The SPARQL Specification<br />http://www.w3.org/TR/rdf-sparql-query/<br />SPARQL implementations<br />http://esw.w3.org/topic/SparqlImplementations<br />SPARQL endpoints<br />http://esw.w3.org/topic/SparqlEndpoints<br />SPARQL Frequently Asked Questions<br />http://www.thefigtrees.net/lee/sw/sparql-faq<br />SPARQL 2 Working Group<br />http://www.w3.org/2009/sparql/wiki/<br />Common SPARQL extensions<br />http://esw.w3.org/topic/SPARQL/Extensions<br />

    ×