. . Multi-agent Semantic Web Systems: RDFa . . . . . Michael Rovatsos School of Informatics 21 February 2011 . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 1 / 22
. . . Intro to Microformats 1 . . . RDFa 2 . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 2 / 22
Review RDF(S) implements part of the vision of the SemWeb: Obtaining network effect for SemWeb requires overcoming the ’Semantic markup bottleneck’. Promising approaches: ◮ Using NLP to convert unstructured information into RDF(S) ◮ Microformats / RDFa for embedding RDF into web documents ◮ Exporting from RDBs to RDF stores. . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 3 / 22
<span class="tel">0131 650-1234</span> <span property="foaf:phone">0131 650-1234</span> Semantic Markup Embedded in HTML, 1 Existing document web is firmly established — can we use this base to support semantic applications? General idea: embed semantic markup into existing (X)HTML tags. . Example: hCard . . . . . . . . . Example: RDFa . . . . . . . . Perspective 1: This is a regular web page, but hey, we can get semantics out of it. Perspective 2: This is machine-readable data, but hey, humans can browse it just like the Good Old Document Web. . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 4 / 22
Semantic Markup Embedded in HTML, 2 Approach is best-suited to information which fits into familiar and frequently used categories, e.g., contact information, calendar events, geo-location information, product reviews, social network information. Why do we need more than existing HTML tags? ◮ In fact, has been explored: cf. “screen scraping”, “wrapper induction” ◮ But traditional HTML tags primarily oriented towards visual rendering. . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 5 / 22
<META NAME="DC.Creator.Address" CONTENT="m.marques-pita@ed.ac.uk"> <META NAME="DC.Creator" CONTENT="Manuel Pita"> <META NAME="DC.Publisher" CONTENT="School of Informatics, ..."> Semantic Markup Embedded in HTML, 3 What about HTML’s META tag? . META in Informatics Web Page . . . . . . . . But: META information is invisible to humans Tends to fall out of synchronization with visible content Has been abused by people concerned with SEO (and therefore can actually harm your Google rank). . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 6 / 22
Microformats, 3 Microformats = Semantic Web for the Impatient ? But so far, efforts to infuse the Web with meaning have gained little traction. These initiatives have been bogged down by complexity and over-ambitious goals, or have simply been too much trouble to implement at a large scale. Proponents of microformats subscribe to general idea of “web of data”, but unconvinced by RDF, OWL, etc. Microformats intended to lower “barrier to entry” — no need to learn a new language. Try to use visible data rather than invisible metadata. Try to re-use existing standards / vocabularies for data modelling; e.g., vCard, iCalendar ⇒ hCard, hCalendar. . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 7 / 22
about href rel about property RDFa RDFa can be seen as a new way of serializing RDF. RDFa = RDF_in_attributes Integrates into XHTML, but simpler than RDF/XML. Motivation is similar to microformats, but ◮ more generic; ◮ can benefit from many existing tools for processing RDF. Two basic cases, corresponding to whether object is literal or resource. subject predicate object literal as object PCDATA or content URI as object . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 8 / 22
RDFa = RDF + XHTML, Case 1 isbn:51649-9 RDF triple dc:title NLP with Python text : XML node tree element: div NLP with Python attribute : class title XML node tree text : element: div + RDFa NLP with Python attribute : class title attribute : about isbn:51649-9 attribute : property dc:title . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 9 / 22
RDFa = RDF + XHTML, Case 1 text : element: div object (literal) NLP with Python attribute :class title attribute :about subject isbn:51649-9 attribute :property predicate dc:title . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 10 / 22
isbn:51649-9 dc:title "NLP with Python" . </div> NLP with Python <div class="title" about="isbn:51649-9" property="dc:title" > </div> NLP with Python <div class="title"> RDFa, Case 1 . RDF triple . . . . . . . . . XHTML . . . . . . . . . XHTML with RDFa . . . . . . . . . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 11 / 22
RDFa = RDF + XHTML, Case 2 isbn:51649-9 orm:ewan_klein RDF triple dc:creator text : XML node tree element: div Ewan Klein attribute : class author XML node tree text : element: div + RDFa Ewan Klein attribute : class author attribute : about isbn:51649-9 attribute :rel dc:creator attribute : href orm:ewan_klein . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 12 / 22
RDFa = RDF + XHTML, Case 2 text : element: div Ewan Klein attribute : class author isbn:51649-9 attribute : about isbn:51649-9 attribute :rel dc:creator dc:creator attribute : href orm:ewan_klein orm:ewan_klein . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 13 / 22
<div class="title" about="isbn:51649-9" </div> Ewan Klein href="orm:ewan_klein"> rel="dc:creator" Ewan Klein </div> <div class="author"> isbn:51649-9 dc:author orm:ewan_klein . RDFa, Case 2 . RDF triple . . . . . . . . . XHTML . . . . . . . . . XHTML with RDFa . . . . . . . . . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 14 / 22
Cafe Web Page . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 15 / 22
resource="ihp:ehk" /> rel="dc:creator" <div about="" Cafe Web Page, 1 . File Metadata, 1 . . . . . . . . Invisible in this case, so vulnerable to previous criticism. Empty value of about refers to current document by default. . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 16 / 22
<a rel="license" href="http://creativecommons.org/licenses/by/3.0/"> All content on this site is licensed under <div class="license"> </div> </a>. a Creative Commons License Cafe Web Page, 2 . File Metadata, 2 . . . . . . . . RDFa slots easily into an a element; other examples of SPO with URI object extrapolate from this. . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 17 / 22
<span rel="foaf:depicts" href="db:Edinburgh" /> content="View of Middle Meadow Walk" /> <span property="dc:subject" <span rel="dc:creator" href="ihp:ehk" /> <img src="mmwalk.jpg" about="mmwalk.jpg"> </img> Cafe Web Page, 3 . Image Metadata . . . . . . . . Object of the Dublin Core subject relation expressed via a literal. But no suitable PCDATA (i.e., text) daughter, so use value of content attribute instead. All spans that are subordinate to the img element share their parent’s specification for about . . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 18 / 22
<tr> </a> href="http://www.artisanroast.co.uk/"> rel="rdfs:seeAlso" typeof="gr:BusinessEntity" <a about=":aroast" <td> </td> Artisan Roast ... </tr> Cafe Web Page, 4 . Table Row, 1 . . . . . . . . Uses GoodRelations ( gr prefix) ontology Special syntax for rdf:type . . . . . . . Michael Rovatsos (School of Informatics) Multi-agent Semantic Web Systems:RDFa 21 February 2011 19 / 22
Recommend
More recommend