Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

469 talk

718 views

Published on

  • Be the first to comment

  • Be the first to like this

469 talk

  1. 1. RDF/XMLA brief introduction<br />Alison Hunt March 26, 2011<br />for LIS469 XML<br />
  2. 2. RDF/XML is a data format<br />It represents information <br />for a data model <br />called RDF<br />
  3. 3. RDFResource Description Frameworkis a data model<br />It structures metadata <br />for<br />the Semantic Web and<br />the RDA content standard<br />(resource description and access)<br />
  4. 4. RDFdescribes a resource<br />LIS469 Class Blog<br />
  5. 5. A resource has properties<br />creator<br />language<br />LIS469 Class Blog<br />format<br />subject<br />
  6. 6. Properties have values<br />creator<br />language<br />LIS469 Class Blog<br />format<br />subject<br />
  7. 7. RDFdescriptions make statements<br />The LIS469 class blog was created by Aaron Rubinstein.<br />The LIS469 class blog is written in English.<br />The LIS469 class blog is formatted as text/HTML.<br />The LIS469 class blog is about the subject of XML.<br />
  8. 8. RDFstatements are triples<br />Resource<br />Subject<br />LIS469 class blog<br />LIS469 class blog<br />LIS469 class blog<br />LIS469 class blog<br />Property<br />Predicate<br />Creator<br />Language<br />Format<br />Subject<br />Value<br />Object<br />Aaron Rubinstein<br />English<br />Text/HTML<br />XML<br />
  9. 9. RDF statements link two things in one direction.<br />Node<br />LIS469 class blog<br />LIS469 class blog<br />LIS469 class blog<br />LIS469 class blog<br />Arc<br />Creator<br />Language<br />Format<br />Subject<br />Node<br />Aaron Rubinstein<br />English<br />Text/HTML<br />XML<br />
  10. 10. RDF statements link two things in one direction.<br />Properties may have multiple values.<br />RDF has several ways to model this:<br />blank nodes, bags, collections, etc.<br />However, the end result will be a set of triples<br /> which link the subject with each value.<br />
  11. 11. RDF statements require URIs that have meaning for computer applications<br />Resource<br />Must be a URI<br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br />Here, the blog URL replaces its name<br />
  12. 12. RDF Shines<br />By using URIs, <br />RDF can describe things that <br />cannot be located or retrieved on the web.<br />People, institutions, cars, concepts…anything.<br />FRBR works, <br />expressions or manifestations<br />Tiger Lily<br />collective amnesia<br />
  13. 13. RDF statements require URIs for properties<br />Resource<br />Must be a URI<br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br />Property<br />Must be a URI<br /><http://purl.org/dc/elements/1.1/creator><br /><http://purl.org/dc/elements/1.1/language><br /><http://purl.org/dc/elements/1.1/format><br /><http://purl.org/dc/elements/1.1/subject><br />Here, Dublin Core URIs are used for the property<br />
  14. 14. Values can be URIs or literal strings of characters<br />Resource<br />Must be a URI<br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br /><http://lis469.wordpress.com/><br />Property<br />Must be a URI<br /><http://purl.org/dc/elements/1.1/creator><br /><http://purl.org/dc/elements/1.1/language><br /><http://purl.org/dc/elements/1.1/format><br /><http://purl.org/dc/elements/1.1/subject><br />Value<br />Can be URI or literal<br />Aaron Rubinstein<br />English<br />Text/html<br /><http://id.loc.gov/authorities/sh97007825#concept><br />Here, XML is identified by a URI <br />from Library of Congress Subject Headings<br />
  15. 15. RDF graph with URIs<br />Note:<br />RDF graphs show<br />literals in a box<br />URIs in an oval<br />We are using a URI as the value of the subject property.<br />So the graph changes from box to oval.<br />This actually indicates a really significant change…<br /><http://purl.org/dc/elements/1.1/creator><br /><http://purl.org/dc/elements/1.1/language><br /><http://lis469.wordpress.com/><br /><http://purl.org/dc/elements/1.1/format><br /><http://purl.org/dc/elements/1.1/subject><br />
  16. 16. A value with a URI can be the subject of other statements<br /><http://purl.org/dc/elements/1.1/creator><br /><http://purl.org/dc/elements/1.1/language><br /><http://purl.org/dc/elements/1.1/format><br /><http://purl.org/dc/elements/1.1/subject><br />Library <br />of<br />Congress<br /><http://purl.org/dc/elements/1.1/creator><br />
  17. 17. RDF links stuff!<br />
  18. 18. RDF shines<br />It is easy <br />to work across <br />different data sources, types and formats.<br />RDF can link things <br />by tapping massive databases of RDF statements called "triplestores."<br />There are more than 27 billion triples stored now.<br />
  19. 19. RDF/XML is a data format<br />001111000010100010000100010010001111000000000011110000000111111111100000000000111111111110000000000011<br />XML document serializes <br />the RDF graph so it can be<br />processed by computers<br />for storage and transmission<br />
  20. 20. RDF expressed as XML<br />RDF<br />XML<br />Class Blog<br />Creator<br /> Aaron Rubinstein<br />Language<br /> English<br />Format<br /> Text-HTML<br />Subject<br /> XML URI<br />The XML format is closed; it will not link like the RDF graph does.<br />
  21. 21. Starting the RDF/XML file<br />RDF<br />RDF is the root element<br />The rdf: prefix is from the rdf namespace<br />We are also using Dublin Core elements<br />XML<br /><?xml version="1.0"?><br /><rdf:RDF<br />xmlns:rdf=http://www.w3.org/1999/02/22-rdf-syntax-ns#<br />xmlns:dc=http://purl.org/dc/elements/1.1/><br />
  22. 22. Where is the resource named?<br />RDF<br />Each resource being described is tagged with the RDF element <description><br />The about attribute spells out the URI<br />Of the resource that is the subject of the RDF statement<br />XML<br /><?xml version="1.0"?><br /><rdf:RDF<br />xmlns:rdf=http://www.w3.org/1999/02/22-rdf-syntax-ns#<br />xmlns:dc=http://purl.org/dc/elements/1.1/><br /><rdf:Description<br />Rdf:about="http://lis469.wordpress.com/"><br />
  23. 23. Properties and values?<br />RDF<br />Properties become child elements of Description.<br />They appear as tags.<br />Literal RDF values become the value of those child elements, between opening and closing tags.<br />When RDF values are expressed as URIs, <br />they become an attribute, called "resource,"<br /> of the child element.<br />XML<br /><?xml version="1.0"?><br /><rdf:RDF<br />xmlns:rdf=http://www.w3.org/1999/02/22-rdf-syntax-ns#<br />xmlns:dc=http://purl.org/dc/elements/1.1/><br /><rdf:Description<br />Rdf:about="http://lis469.wordpress.com/"><br /><dc:creator>Aaron Rubinstein</dc:creator><br /><dc:language>English</dc:language><br /><dc:format>text/HTML</dc:format><br /><dc:subjectrdf:resource=" http://id.loc.gov/authorities/sh97007825#concept "/><br /></rdf:Description><br /></rdf:RDF><br />
  24. 24. But properties should be URIs!<br />Namespace declarations generate full URIs <br />for each property<br />dc: is equivalent to http://purl.org/dc/elements/1.1/<br /><dc:format>text/HTML</dc:format><br />is processed as<br /><http://purl.org/dc/elements/1.1/ format> text/HTML </ <http://purl.org/dc/elements/1.1/ format><br />
  25. 25. RDF expressed as XML<br />RDF<br />XML<br /><?xml version="1.0"?><br /><rdf:RDF<br />xmlns:rdf=http://www.w3.org/1999/02/22-rdf-syntax-ns#<br />xmlns:dc=http://purl.org/dc/elements/1.1/><br /><rdf:Description<br />Rdf:about="http://lis469.wordpress.com/"><br /><dc:creator>Aaron Rubinstein</dc:creator><br /><dc:language>English</dc:language><br /><dc:format>text/HTML</dc:format><br /><dc:subjectrdf:resource=" http://id.loc.gov/authorities/sh97007825#concept "/><br /></rdf:Description><br /></rdf:RDF><br />
  26. 26. RDF/XML is not the only choice<br />PROS<br />RDF/XML is the syntax primarily <br />used by the W3C from the start<br />It plays well with the family of XML technologies.<br />XML uses namespaces and can tag (i.e. express RDF properties) with ultimate flexibility.<br />CONS<br />RDF/XML files are hard for people to read.<br />Namespaces don't always behave the way we expect<br />Most of the developers who have to actually generate linked data find RDF/XML clunky <br />RDF/XML obscures triples <br />
  27. 27. Other RDF data formats are<br />RDFa<br />Embeds RDF metadata in html. Part of Drupal7.<br />TURTLE<br />Very easy for people to read. Preserves RDF triples.<br />JSON<br />Supported by major web applications like JavaScript,<br />so easy to process and familiar to developer community. <br />
  28. 28. You should know<br />W3C is overhauling its RDF recommendations<br />http://www.w3.org/2011/01/rdf-wg-charter<br />You can create your own personal URI<br />http://www.foaf-project.org/<br />For a great overview, skim the new e-book<br />Linked Data: Evolving the Web into a Global Data Space<br />http://linkeddatabook.com/editions/1.0<br />DBPedia is the hub of RDF-linked data<br />http://dbpedia.org/About<br />
  29. 29. The Linked World<br />Linking Open Data cloud diagram, by Richard Cyganiak and AnjaJentzsch. http://lod-cloud.net/<br />

×