Successfully reported this slideshow.
RDFa Everywhere


                                                                        Knud Möller, DERI, NUI Galway


...
Previously on Web Directions South...




                             http://www.slideshare.net/mark.birbeck/
           ...
Recent Developments in RDFa


•important new adopters!
    – facebook, Drupal 7, ...
•W3C RDFa Working Group
    – work un...
Wait - but what is RDFa?


•basically: a way to very precisely mark up data in a web
 page




4
RDFa Toy Example




5
RDFa Toy Example (ctd.)

                                                                   "My Homer
                    ...
RDFa Toy Example (ctd.)

       <html>
        <head>
         <title>My Homer Page</title>
        </head>
        <body>...
RDFa Toy Example (ctd.)

       <html>
       <html prefix="foaf: http://xmlns.com/foaf/0.1/
        <head>       dct: htt...
Wait - but what is RDFa?


•basically: a way to very precisely mark up data in a web
 page (or other document)
•RDFa = “RD...
Wait - but what is RDFa?


 •basically: a way to very precisely mark up data in a web
  page (or other document)
 •RDFa = ...
Wait - but what is RDFa?


 •basically: a way to very precisely mark up data in a web
  page (or other document)
 •RDFa = ...
Some Old and New Attributes (there are more!)


•@about to say what some information is about (the
 subject) <span about="...
Adopters of RDFa - Facebook’s OGP


•April 2010: Facebook announces RDFa in Open Graph
 Protocol
•Any web page can become ...
Adopters of RDFa - Facebook’s OGP (ctd.)




11
Adopters of RDFa - Facebook’s OGP (ctd.)


<head>
  <meta about="http://data.semanticweb.org/workshop/scripting/2008/paper...
Adopters of RDFa - Facebook’s OGP (ctd.)




12
Adopters of RDFa - Facebook’s OGP (ctd.)




12
Adopters of RDFa - Drupal


•Drupal is one of the top 3 open source CMSs [2]
•Lots of organisations, companies, media, adm...
Adopters of RDFa - Drupal (ctd.)
Digital Enterprise Research Institute                                                    ...
Adopters of RDFa - Drupal (ctd.)
Digital Enterprise Research Institute                                                    ...
Adopters of RDFa - Drupal (ctd.)




15
Adopters of RDFa - Drupal (ctd.)




16
Adopters of RDFa - many others


•Search Engines as RDFa consumers
     – Google (Rich Snippets)
     – Yahoo! (Searchmonk...
Linked (Open) Data


•linked data instead of linked documents
•data producers - companies, governments, media,
 academia, ...
Linked (Open) Data (ctd.)




                            February 2008




19
Linked (Open) Data (ctd.)




                            February 2008


                                      July 2009
...
Linked (Open) Data (ctd.)




                            February 2008


                                      July 2009
...
RDFa as a Linked (Open) Data-enabler


•RDFa is automatically part of the Web of Data
•maybe few or no links in the beginn...
The LATC Project


•EU “Support Action” Project for Linked Open Data [10]

1. Deploy a 24/7 infrastructure to continuously...
A Little Bit of RDFa History


•2004 - early work on RDFa
•2004 - “RDF in XHTML” Task Force started
•10/2008 - RDFa 1.0 be...
New Developments - RDFa Core 1.1


•backwards-compatible to RDFa 1.0
•RDFa no longer tied to one language
•instead embedde...
New Developments - RDFa Core 1.1 (ctd.)


•no more reliance on @xmlns (too much tied to XML)
     – instead the more gener...
New Developments - RDFa Core 1.1 (ctd.)


•no more reliance on @xmlns (too much tied to XML)
     – instead the more gener...
New Developments - RDFa Core 1.1 (ctd.)


•no more reliance on @xmlns (too much tied to XML)
     – instead the more gener...
New Developments - RDFa Core 1.1 (ctd.)


•no more reliance on @xmlns (too much tied to XML)
     – instead the more gener...
New Developments - RDFa API


•focussing on using, rather than producing data
•ideally one day supported natively by brows...
New Developments - RDFa API


•access both data and DOM elements
     data: var bob = document.getItemBySubject(“#homer”)
...
New Developments - RDFa API


•access both data and DOM elements
     data: var bob = document.getItemBySubject(“#homer”)
...
New Developments - RDFa API (ctd.)


                                                getItemBySubject("#bob") .get("foaf.n...
RDFa Tools


•Online Parsers/Syntax Checkers
     – RDFa Distiller: http://www.w3.org/2007/08/pyRdfa/
     – checkrdfa: ht...
RDFa Tools (ctd.)




29
What to Take Home


•RDFa - embed metadata in web pages (and any other
 markup language)
•RDFa as key enabler for Linked (...
References


(1) On OGP: http://blog.mayflower.de/archives/551-Facebook-
     Open-Graph.html
(2) Shreves, Ric. “Open Sourc...
References (ctd.)


(5) Effect of RDFa for BestBuy ranking in Google: http://
     priyankmohan.blogspot.com/2009/12/onlin...
References (ctd.)


(9) Bizer, Chris. "Pay-as-you-go Data Integration on the
    public Web of Linked Data". Keynote at FI...
Upcoming SlideShare
Loading in …5
×

RDFa Everywhere

8,268 views

Published on

What is RDFa, what is new in RDFa 1.1, why is important for Linked Data, who uses it and how? - Talk given at WebDirectionsSouth 2010 in Sydney, 14/10/2010

Published in: Technology, Education

RDFa Everywhere

  1. 1. RDFa Everywhere Knud Möller, DERI, NUI Galway WebDirections South 2010 14/10/2010 13/03/2008 FAST kick-off, Madrid, 2008  Copyright 2010 Digital Enterprise Research Institute. All rights reserved.
  2. 2. Previously on Web Directions South... http://www.slideshare.net/mark.birbeck/ rdfa-what-happens-when-pages-get-smart 2
  3. 3. Recent Developments in RDFa •important new adopters! – facebook, Drupal 7, ... •W3C RDFa Working Group – work under way for RDFa 1.1 – RDFa API •new tools 3
  4. 4. Wait - but what is RDFa? •basically: a way to very precisely mark up data in a web page 4
  5. 5. RDFa Toy Example 5
  6. 6. RDFa Toy Example (ctd.) "My Homer index.html dct:title Page" foaf:primaryTopic index.html foaf:name "Homer" #me rdf:type foaf:knows foaf:Person rdf:type index.html foaf:name "Marge" #marge foaf:depiction marge- simpson1.jpg 6
  7. 7. RDFa Toy Example (ctd.) <html> <head> <title>My Homer Page</title> </head> <body> <h1>My Homer Page</h1> <p>Hi! My name is Homer Simpson, and this is my <b>lovely wife</b>, Marge. </p> <img src="http://missmba.files.wordpress.com/2009/10/marge- simpson1.jpg"/> </body> </html> 7
  8. 8. RDFa Toy Example (ctd.) <html> <html prefix="foaf: http://xmlns.com/foaf/0.1/ <head> dct: http://purl.org/dc/terms/"> <title>My Homer Page</title> <head> </head> about="" property="dct:title">My Homer Page</title> <title <body> </head> <body> Homer Page</h1> <h1>My <h1 about="">My <p>Hi! My name is Homer Simpson, <span rel="foaf:primaryTopic" resource="#me">Homer</span> Page</h1> and this is my <b>lovely wife</b>, Marge. <p about="#me" typeof="foaf:Person">Hi! My name is </p> <span property="foaf:name">Homer Simpson</span>, and <span rel="foaf:knows"> <img <span about="#marge" typeof="foaf:Person">this is my src="http://missmba.files.wordpress.com/2009/10/marge- <b>lovely wife</b>, simpson1.jpg"/> <span property="foaf:firstName">Marge</span></span></span>. </body> </p> </html> <img resource="#marge" rev="foaf:depiction" src="http://missmba.files.wordpress.com/2009/10/marge- simpson1.jpg"/> </body> 7
  9. 9. Wait - but what is RDFa? •basically: a way to very precisely mark up data in a web page (or other document) •RDFa = “RDF in attributes” •Triple: (Subject, Predicate, Object) 8
  10. 10. Wait - but what is RDFa? •basically: a way to very precisely mark up data in a web page (or other document) •RDFa = “RDF in attributes” •Triple: (Subject, Predicate, Object) <#me> foaf:knows <#marge> . <#me> foaf:name “Homer” . 8
  11. 11. Wait - but what is RDFa? •basically: a way to very precisely mark up data in a web page (or other document) •RDFa = “RDF in attributes” •Triple: (Subject, Predicate, Object) "My Homer index.html dct:title Page" foaf:primaryTopic index.html foaf:name "Homer" #me rdf:type <#me> foaf:knows <#marge> . foaf:Person foaf:knows rdf:type <#me> foaf:name “Homer” . index.html #marge foaf:name "Marge" foaf:depiction marge- simpson1.jpg 8
  12. 12. Some Old and New Attributes (there are more!) •@about to say what some information is about (the subject) <span about="#marge" typeof="foaf:Person">...</span> •@typeof to say what kind of thing something is (its class) <span about="#marge" typeof="foaf:Person">...</span> •@rel to say how one thing relates to another (predicate) <a rel="cc:license" href="http://creativecommons.org/ licenses/by-nc-nd/3.0/">Creative Commons License</a> •@href to say what something related to (the object) <a rel="cc:license" href="http://creativecommons.org/ licenses/by-nc-nd/3.0/">Creative Commons License</a> •@content to provide machine-readable content (a literal object) ... starts <span property="cal:dtstart" content="2010-10-14" datatype="xsd:dateTime">today</span>! 9
  13. 13. Adopters of RDFa - Facebook’s OGP •April 2010: Facebook announces RDFa in Open Graph Protocol •Any web page can become a node in the graph by adding some simple markup [1] 10
  14. 14. Adopters of RDFa - Facebook’s OGP (ctd.) 11
  15. 15. Adopters of RDFa - Facebook’s OGP (ctd.) <head> <meta about="http://data.semanticweb.org/workshop/scripting/2008/paper/9" property="og:title" content="World of WebCraft - Mashing up World of Warcraft and the Web"/> <meta about="http://data.semanticweb.org/workshop/scripting/2008/paper/9" property="og:type" content="article"/> <meta about="http://data.semanticweb.org/workshop/scripting/2008/paper/9" property="og:url" content="http://data.semanticweb.org/workshop/scripting/2008/paper/9"/> <meta about="http://data.semanticweb.org/workshop/scripting/2008/paper/9" property="og:image" content="http://data.semanticweb.org/images/paper_icon_100.png"/> <meta about="http://data.semanticweb.org/workshop/scripting/2008/paper/9" property="og:site_name" content="Semantic Web Dog Food"/> ... </head> 11
  16. 16. Adopters of RDFa - Facebook’s OGP (ctd.) 12
  17. 17. Adopters of RDFa - Facebook’s OGP (ctd.) 12
  18. 18. Adopters of RDFa - Drupal •Drupal is one of the top 3 open source CMSs [2] •Lots of organisations, companies, media, administrations, politicians, universities, etc. all run Drupal [3] •Drupal 7 will provide RDFa support right out of the box! •By default, common Drupal content types and data fields are mapped to vocabularies like Dublin Core, RSS, SIOC, FOAF, SKOS, etc. 13
  19. 19. Adopters of RDFa - Drupal (ctd.) Digital Enterprise Research Institute www.deri.ie sioc:UserAccount foaf:name sioc: has_creator foaf:page sioc:Item, foaf:Document sioc:topic skos:Concept Produce and Consume skos:prefLabel, Linked Data with Drupal dc:title rdfs:label posted on October 22 by Stéphane dc:created, dc:date sioc:reply_of skos:description content:encoded Produce and Consume Linked Data with Drupal! is the skos:inScheme title of the paper I will be presenting next week at dc:modified the 8th International Semantic Web Conference (ISWC 2009) in Washington, DC. sioc:num_replies sioc:Post, Drupal ISWC RDFa sioc:last_activity_date sioct:Comment dc:title Wow, that’s rad! posted on October 23 by Lin dc:created, dc:date Nice work! content:encoded dc:modified [4] 14 7
  20. 20. Adopters of RDFa - Drupal (ctd.) Digital Enterprise Research Institute www.deri.ie Digital Enterprise Research Institute www.deri.ie sioc:UserAccount foaf:name sioc: posted on foaf:page has_creator <span property="dc:date dc:created" sioc:Item, content="2009-10-22T08:03:26-05:00" Produce and Consume foaf:Document sioc:topic datatype="xsd:dateTime"> skos:Concept Produce and Consume Linked Data with Drupal October 22 skos:prefLabel, Linked Data with Drupal dc:title rdfs:label posted on October 22 by Stéphane </span> posted on October 22 by Stéphane dc:created, dc:date by sioc:reply_of skos:description Produce and Consume Linked Data with Drupal! is the <span rel="sioc:has_creator"> content:encoded title of the paper I will Linked Data with Drupal! at the Produce and Consume be presenting next week is <span about="/user/6" skos:inScheme the 8th International Semantic Web Conference at title of the paper I will be presenting next week dc:modified (ISWC 2009) in Washington, DC. Web Conference the 8th International Semantic typeof="sioc:UserAccount" (ISWC 2009) in Washington, DC. sioc:num_repliesproperty="foaf:name"> Drupal ISWC RDFa sioc:Post, stephane Drupal ISWC RDFa sioc:last_activity_date sioct:Comment </span> Wow, that’s rad! </span> dc:title Wow, that’s rad! posted on October 23 by Lin posted on October 23 by Lin dc:created, dc:date Nice work! Nice work! content:encoded dc:modified [4] 8 14 7
  21. 21. Adopters of RDFa - Drupal (ctd.) 15
  22. 22. Adopters of RDFa - Drupal (ctd.) 16
  23. 23. Adopters of RDFa - many others •Search Engines as RDFa consumers – Google (Rich Snippets) – Yahoo! (Searchmonkey) •Retailers as RDFa producers – BestBuy [5], Overstock – Tesco •... 17
  24. 24. Linked (Open) Data •linked data instead of linked documents •data producers - companies, governments, media, academia, private individuals, etc. - open their structured data to the public 1. Identify everything with a URI. 2. Use “http://” URIs - otherwise they cannot be found! 3. Provide useful information at each URI. 4. Include links between datasets. [6] 18
  25. 25. Linked (Open) Data (ctd.) February 2008 19
  26. 26. Linked (Open) Data (ctd.) February 2008 July 2009 19
  27. 27. Linked (Open) Data (ctd.) February 2008 July 2009 [7,8] 19
  28. 28. RDFa as a Linked (Open) Data-enabler •RDFa is automatically part of the Web of Data •maybe few or no links in the beginning, but ... •data can be integrated, mashed up, compared, cleaned, enhanced, etc. •data producers, consumers and third parties can all contribute in a “pay-as-you-go fashion” [9] •RDFa requires no set-up - anyone on the Web can do it! •Platforms and tools like Drupal make it even easier •The first SW technology to receive serious attention and uptake - something must be right about it! 20
  29. 29. The LATC Project •EU “Support Action” Project for Linked Open Data [10] 1. Deploy a 24/7 infrastructure to continuously monitor and improve the quality of data links within the Linking Open Data cloud. 2. Assemble and maintain a library of open source Linked Data tools and provide a data source inventory to the community. 3. Create and maintain a test-bed for data-intensive applications by publishing EU-produced datasets and by interlinking them with other governmental data. 4. Support institutions as well as individuals with tutorials and best practices concerning Linked Data publication and consumption. 21
  30. 30. A Little Bit of RDFa History •2004 - early work on RDFa •2004 - “RDF in XHTML” Task Force started •10/2008 - RDFa 1.0 becomes W3C Recommendation •01/2009 - Task Force closed •02/2010 - RDFa Working Group started (RDFa 1.1) •04/2010 - First Public Working Drafts •10/2010 - RDFa 1.1 Core, RDFa 1.1 API and XHTML +RDFa 1.1 Last Call - Coming up soon! •04/2011 - Recommendation planned 22
  31. 31. New Developments - RDFa Core 1.1 •backwards-compatible to RDFa 1.0 •RDFa no longer tied to one language •instead embedded in any suitable host language Host Languages •RDFa Core defines attributes, precise XHTML processing model, requirements on HTML5 host languages, etc. RDFa •XHTML+RDFa 1.1 defines a number SVG Core of language-specific terms, and ... provides a formal schema and DTD. ODF 23
  32. 32. New Developments - RDFa Core 1.1 (ctd.) •no more reliance on @xmlns (too much tied to XML) – instead the more generic @prefix <html xmlns:foaf="http://xmlns.com/foaf/0.1/" xmlns:dct="http://purl.org/dc/terms/"> 24
  33. 33. New Developments - RDFa Core 1.1 (ctd.) •no more reliance on @xmlns (too much tied to XML) – instead the more generic @prefix prefix="foaf: http://xmlns.com/foaf/0.1/ <html xmlns:foaf="http://xmlns.com/foaf/0.1/" dct: http://purl.org/dc/terms/"> xmlns:dct="http://purl.org/dc/terms/"> 24
  34. 34. New Developments - RDFa Core 1.1 (ctd.) •no more reliance on @xmlns (too much tied to XML) – instead the more generic @prefix prefix="foaf: http://xmlns.com/foaf/0.1/ <html xmlns:foaf="http://xmlns.com/foaf/0.1/" dct: http://purl.org/dc/terms/"> xmlns:dct="http://purl.org/dc/terms/"> – alternatively @vocab, to avoid prefixes altogether <?xml version="1.0" encoding="UTF-8"?> <html prefix="dct: http://purl.org/dc/terms/" vocab="http://xmlns.com/foaf/0.1/"> ... <span property="name">Homer Simpson</span>, and <span rel="knows"> 24
  35. 35. New Developments - RDFa Core 1.1 (ctd.) •no more reliance on @xmlns (too much tied to XML) – instead the more generic @prefix prefix="foaf: http://xmlns.com/foaf/0.1/ <html xmlns:foaf="http://xmlns.com/foaf/0.1/" dct: http://purl.org/dc/terms/"> xmlns:dct="http://purl.org/dc/terms/"> – alternatively @vocab, to avoid prefixes altogether <?xml version="1.0" encoding="UTF-8"?> <html prefix="dct: http://purl.org/dc/terms/" vocab="http://xmlns.com/foaf/0.1/"> ... <span property="name">Homer Simpson</span>, and <span rel="knows"> – or even load an external document through @profile, which defines terms and/or prefix mappings 24
  36. 36. New Developments - RDFa API •focussing on using, rather than producing data •ideally one day supported natively by browsers •allow abstraction from underlying RDF model •design oriented on other DOM-based APIs document.getElementsBySubject() ≈ document.getElementsById() •first target: ECMAScript, but other languages should work just as well 25
  37. 37. New Developments - RDFa API •access both data and DOM elements data: var bob = document.getItemBySubject(“#homer”) DOM: var names = document.getElementsByProperty(“foaf:name”) •extensibility: non-RDFa parsers (Microformats, Microdata, etc.), other datastores, etc. 26
  38. 38. New Developments - RDFa API •access both data and DOM elements data: var bob = document.getItemBySubject(“#homer”) DOM: var names = document.getElementsByProperty(“foaf:name”) •extensibility: non-RDFa parsers (Microformats, Microdata, etc.), other datastores, etc. 26
  39. 39. New Developments - RDFa API (ctd.) getItemBySubject("#bob") .get("foaf.name") "Bob" "Jane" PropertyGroups foaf:name foaf:name ( (“foaf:name”, “Bob”), #bob foaf:knows #jane (“foaf:knows”, “#jane”), (“foaf:interest”, “#foo”) ) foaf:interest #foo rdfs:label "Foo" 27
  40. 40. RDFa Tools •Online Parsers/Syntax Checkers – RDFa Distiller: http://www.w3.org/2007/08/pyRdfa/ – checkrdfa: http://check.rdfa.info/ - also allows to check FB OGP and Google Rich Snippets •Check out: http://rdfa.info/wiki/Tools 28
  41. 41. RDFa Tools (ctd.) 29
  42. 42. What to Take Home •RDFa - embed metadata in web pages (and any other markup language) •RDFa as key enabler for Linked (Open) Data •since RDFa 1.0 (2008) – serious increase in uptake (Facebook, Drupal, Google, Yahoo!, ...) - there is RDFa everywhere! – extensions and improvements to the language as RDFa 1.1 – separate Core and host languages – RDFa API for usage and consumption of data Thank You! 30
  43. 43. References (1) On OGP: http://blog.mayflower.de/archives/551-Facebook- Open-Graph.html (2) Shreves, Ric. “Open Source CMS Market Share”. http://www.waterandstone.com/downloads/ 2008OpenSourceCMSMarketSurvey.pdf (3) Dries Buytaert’s Blog: http://buytaert.net/ (4) Corlosquet, Clark, Passant, Polleres. “How to Build Linked Data Sites with Drupal 7 and RDFa”. http:// www.slideshare.net/scorlosquet/how-to-build-linked-data-sites- with-drupal-7-and-rdfa 31
  44. 44. References (ctd.) (5) Effect of RDFa for BestBuy ranking in Google: http:// priyankmohan.blogspot.com/2009/12/online-retail-how-best- buy-is-using.html (6) Berners-Lee, T. Linked Data. http://www.w3.org/ DesignIssues/LinkedData.html (7) Linking Open Data cloud diagram, by Richard Cyganiak and Anja Jentzsch. http://lod-cloud.net/ (8) “LOD Dataset Catalog and updated version of LOD Cloud Diagram released”. http://www.wiwiss.fu-berlin.de/ en/institute/pwo/bizer/news/lodCloudSep2010.html 32
  45. 45. References (ctd.) (9) Bizer, Chris. "Pay-as-you-go Data Integration on the public Web of Linked Data". Keynote at FIS2010. http://bit.ly/a3r3Yv (10)LATC Project. http://latc-project.eu/ (11) RDFa 1.1 Core: http://www.w3.org/TR/rdfa-core/ (12) RDFa API: http://www.w3.org/TR/rdfa-api/ 33

×