GoodRelations vs. Google RDFa vs. Open Graph vs. hProduct/hListing: Using GoodRelations in 10 Triples

Dear all:

Some people think that the GoodRelations ontology for e-commerce 
(http://purl.org/goodrelations/) is powerful, but complex.
I think it is important for everybody in the community to know that 
GoodRelations can be as simple (or simpler) than any more lightweight 
approach for product markup, as long as you compare the same level of 
granularity.

Below, please find an example of offering a car for sales in just ten 
(!) triples.

Of course, you can do more with GoodRelations than just encoding a price 
and carrying the semantics of the product itself in a string.

The important message in here is that simple chunks of data are as 
simple in GoodRelations as they are in hProduct/hListing microformats, 
Google's RDFa vocabulary, or the Open Graph product markup.

The key difference is that GoodRelations has a much more extensible and, 
in my biased ;-) judgement: cleaner, conceptual model so that IF you 
have more granular data available, THEN you can expose it, and make your 
products more findable on the Web.

For example, GoodRelations distinguishes between products and product 
models / datasheets. That allows for powerful linking between individual 
items and rich technical specifications from the manufacturer's page.

The Open Graph approach seems to use a plain "topic" semantics, which 
mixes items, datasheets, and offers.

Please keep that in mind and spread the word.

Here is the markup.

Best wishes

Martin


Turtle/N3:
=========
@prefix foo: <http://www.example.com/xyz#> .
@prefix gr: <http://purl.org/goodrelations/v1#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .

foo:company a gr:BusinessEntity;
     gr:legalName "Hepp Space Ventures Inc.";
     gr:offers foo:offering.

foo:offering a gr:Offering;
     rdfs:label "Volkswagen Station Wagon, 4WD, 400 $"@en;
     rdfs:description "I sell my old Volkswagen Station Wagon, 4WD, for 
400 $"@en;
     gr:hasPriceSpecification
         [ a gr:UnitPriceSpecification;
             gr:hasCurrencyValue "400"^^xsd:string;
             gr:hasCurrency "USD"^^xsd:string. ].

RDFa:
====
<div xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" 
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" 
xmlns="http://www.w3.org/1999/xhtml" 
xmlns:gr="http://purl.org/goodrelations/v1#" 
xmlns:foo="http://www.example.com/xyz#" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema#">
<div about="http://www.example.com/xyz#company" typeof="gr:BusinessEntity">
<div property="gr:legalName" content="Hepp Space Ventures Inc."></div>
<div rel="gr:offers">
<div about="http://www.example.com/xyz#offering" typeof="gr:Offering">
<div property="rdfs:label" content="Volkswagen Station Wagon, 4WD, 400 
$" xml:lang="en"></div>
<div property="rdfs:description" content="I sell my old Volkswagen 
Station Wagon, 4WD, for 400 $" xml:lang="en"></div>
<div rel="gr:hasPriceSpecification">
<div typeof="gr:UnitPriceSpecification">
<div property="gr:hasCurrency" content="USD" datatype="xsd:string"></div>
<div property="gr:hasCurrencyValue" content="400" 
datatype="xsd:string"></div>
</div>
</div>
</div>
</div>
</div>
</div>

RDF/XML:
=======

<?xml version="1.0"?>
<rdf:RDF xmlns:gr="http://purl.org/goodrelations/v1#" 
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" 
xmlns:foo="http://www.example.com/xyz#" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema#" 
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#">
<gr:BusinessEntity rdf:about="http://www.example.com/xyz#company">
<gr:legalName>Hepp Space Ventures Inc.</gr:legalName>
<gr:offers>
<gr:Offering rdf:about="http://www.example.com/xyz#offering">
<rdfs:label xml:lang="en">Volkswagen Station Wagon, 4WD, 400 $</rdfs:label>
<rdfs:description xml:lang="en">I sell my old Volkswagen Station Wagon, 
4WD, for 400 $</rdfs:description>
<gr:hasPriceSpecification>
<gr:UnitPriceSpecification>
<gr:hasCurrencyValue 
rdf:datatype="http://www.w3.org/2001/XMLSchema#string">400</gr:hasCurrencyValue>
<gr:hasCurrency 
rdf:datatype="http://www.w3.org/2001/XMLSchema#string">USD</gr:hasCurrency>
</gr:UnitPriceSpecification>
</gr:hasPriceSpecification>
</gr:Offering>
</gr:offers>
</gr:BusinessEntity>
</rdf:RDF>






-- 
--------------------------------------------------------------
martin hepp
e-business&  web science research group
universitaet der bundeswehr muenchen

e-mail:  hepp@ebusiness-unibw.org
phone:   +49-(0)89-6004-4217
fax:     +49-(0)89-6004-4620
www:     http://www.unibw.de/ebusiness/ (group)
          http://www.heppnetz.de/ (personal)
skype:   mfhepp
twitter: mfhepp

Check out GoodRelations for E-Commerce on the Web of Linked Data!
=================================================================

Project page:
http://purl.org/goodrelations/

Resources for developers:
http://www.ebusiness-unibw.org/wiki/GoodRelations

Webcasts:
Overview - http://www.heppnetz.de/projects/goodrelations/webcast/
How-to   - http://vimeo.com/7583816

Recipe for Yahoo SearchMonkey:
http://www.ebusiness-unibw.org/wiki/GoodRelations_and_Yahoo_SearchMonkey

Talk at the Semantic Technology Conference 2009:
"Semantic Web-based E-Commerce: The GoodRelations Ontology"
http://www.slideshare.net/mhepp/semantic-webbased-ecommerce-the-goodrelations-ontology-1535287

Overview article on Semantic Universe:
http://www.semanticuniverse.com/articles-semantic-web-based-e-commerce-webmasters-get-ready.html

Tutorial materials:
ISWC 2009 Tutorial: The Web of Data for E-Commerce in Brief: A Hands-on 
Introduction to the GoodRelations Ontology, RDFa, and Yahoo! SearchMonkey
http://www.ebusiness-unibw.org/wiki/Web_of_Data_for_E-Commerce_Tutorial_ISWC2009

Received on Monday, 3 May 2010 08:39:06 UTC