[rdfweb-dev] General question about RDF in FOAF

Leigh.Dodds at ingenta.com Leigh.Dodds at ingenta.com
Mon Mar 1 19:50:55 UTC 2004


Quoting Alex Kilpatrick <AlexK at hcitraining.com>:
> 
> This question is more general than FOAF, but I think it is still
> relevant to the group.  Let's say I want to use the FOAF RDF schema,
> but I want to extend with a bunch of other stuff for my own use.  How
> should I handle the namespaces in that case?  For example, if I want to 
> add (silly example) a relationship called "favorite food".  I assume I
> wouldn't use:
> 
> <foaf:favoriteFood>
> 
> because that is not part of the published schema.  Would I instead use
> something like this:
> 
> <myCustomfoaf:favoriteFood>

Yes that's the correct approach. One shouldn't add elements to someone 
else's namespace, although obviously there's nothing wrong with proposing 
new elements.

You're also not really "extending" FOAF. You're going to end up defining 
a new schema with some new properties that can be used to annotate the 
Classes already defined in FOAF. It's more "mixing" rather than "extending".
(If FOAF were a plain XML vocabulary then you would have to extend the schema 
definition).

I went through this process recently to define a simple schema to describe 
reading lists [1]. This defines one new Class (Book) with a single property 
(isbn) and some properties that can be used to relate a foaf:Person to 
a book:Book, e.g. is reading, has read, etc.

To continue your example you may end up with: 

* food:Food -- a specific food stuff.

* food:favouriteFood -- a new property that can be applied to a 
foaf:Person to relate her/him to their favourite food:Food.

An important consideration is whether any new class you define has an 
identifying property (an Inverse-Functional-Property in OWL parlance). 
It's important to capture/define these as it allows statements about 
the same food:Food (for example) to be collated (smushed). This will 
allow an application to work out all the people who like the same 
food.

Another important step when writing a new schema (IMHO, anyway) 
is to relate it to other terms in existing vocabularies, e.g. dublin core, 
Wordnet, etc. The latter is especially useful as you're essentially tieing 
your schema into a standard dictionary.

Hope thats useful,

L.

[1]. http://purl.org/net/schemas/book/



More information about the foaf-dev mailing list