Re: Help on RDF model design

Hey Andrew.

> I'm trying to learn how to design RDF models, and am starting with a
> simple one for book reviews.  Can someone please critique the approach
> taken here, and point out bad design decisions, or principles that
> should be followed?

I'll be happy to provide all the abuse you need  :-)


> Here's the basic model. A resource R can be stated to be a review of
> resources T1, T2, T3.  (You might be reviewing three new books, or all
> the titles in a series.)  Reviews have the following properties:
> 
>   Items -> a list of resources T1, T2, T3, ...
>   Author -> string
>   Date -> string 
>   
> The resources T1, T2, ... should then each have a title and author.
> (A real application would likely use Dublin Core for this, of course.)
> A sample RDF file in this model would then look like this:
> 
> <rdf:RDF xmlns:rdf="..." xmlns:rev="...">
>   <rdf:Description 
>     about="http://..."

According to recent syntax prescriptions (with which I have stated my public 
disagreement) this should actually be "rdf:about=''".  Basically the WG says 
all attributes should be prefixed.


>     rev:date="1999-04-14" rev:author="A.M. Kuchling"
>     rev:items="urn:isbn:123456789" />
> 
>   <rdf:Description about="urn:isbn:123456789" 

ditto


>      rev:author="Bob Brier"
>      rev:title="The Encyclopedia of Mummies" />
> 
>  </rdf:RDF>
> 
> Q1. Are there common principles for model design that should be followed?
> (Pointers to articles/papers would be greatly appreciated.) Does this
> simple model break any of them?

Your example is too simple for too deep a navel-gazing on modeling, I think, 
but in general, I'll plug a couple of my own articles on modeling with RDF:

http://www-106.ibm.com/developerworks/xml/library/x-think8.html
http://www-106.ibm.com/developerworks/xml/library/x-think9.html


> Q2. rev:author is here given as a human-readable string.  It could
> also be given as a URI, if someone were to assign URIs to people (say,
> authors or mummy researchers or Virginia residents).  Must the book
> review model state its expectation of the property value, whether it's
> a URI or an arbitrary string?  Can the model support both
> possibilities, and if so, how?  Or do you need to have two distinct
> properties in this case, i.e. rev:author="Bob Brier" and
> rev:authorURI="http://people.org/..."

I do obliquely address this very question in the articles above.  I tend to 
prefer to point to a resource, which can then be described using vCard, foaf, 
etc.  It can be a blank node (anonymous resource) or one could use a mailbox 
to ID it.


> Q3. If a review covers multiple resources, the value of the items
> property would have to be an RDF Bag or Sequence.  (RDF's Alternative
> doesn't make sense here.)  Should the model specify which type is
> expected?

I personally have not used RDF 1.0 containers for over a year.  I think 
they're quite kludgy and awkward.  What I actually use instead depends on the 
problem at hand.  In your case, I'd just use multiple simple statements:

  <rdf:Description rdf:about="http://..."
    rev:date="1999-04-14" rev:author="A.M. Kuchling"
    rev:item="book1" rev:item="book2"/>


> "As an historian, I simply don't believe in coincidence."
>     -- Robertson Davies, _The Manticore_

Brilliant, brilliant book & trilogy.


-- 
Uche Ogbuji                                    Fourthought, Inc.
http://uche.ogbuji.net    http://4Suite.org    http://fourthought.com
Track chair, XML/Web Services One (San Jose, Boston): 
http://www.xmlconference.com/
DAML Reference - http://www.xml.com/pub/a/2002/05/01/damlref.html
The Languages of the Semantic Web - http://www.newarchitectmag.com/documents/s=
2453/new1020218556549/index.html
XML, The Model Driven Architecture, and RDF @ XML Europe - 
http://www.xmleurope.com/2002/kttrack.asp#themodel

Received on Friday, 31 May 2002 17:46:00 UTC