Foaf in n3

Having got started with n3 I made myself a foaf file using it

So now I've started with notation3 I am itching for places to use it. For this reason I decided to make myself a foaf file. Happily, this is really straightforward using n3. My foaf.n3 looks like this:

@keywords a.
@prefix : <>.
@prefix wot: <>.
@prefix dc: <>.
@prefix x: <#>.

x:this a PersonalProfileDocument;
    wot:assurance "";
    maker x:me;
    primaryTopic x:me;
    dc:title "Sean Hunter's FOAF file";
    dc:identifier "".

x:me a Person; 
    name "Sean Hunter"; 
    gender "male";
    title "Mr"; 
    givenname "Sean";
    family_name "Hunter";
    homepage <>;
    mbox_sha1sum "f5a2eaad7e46af80de0bc48e6db72efebe382da0";
    plan """
---  ---
---  ---
---  ---             Darkening of the Light. In adversity       
--------             It furthers one to be persevering.
---  ---

...which when I do python /usr/bin/ foaf.n3 --rdf >| foaf.rdf generates a foaf.rdf file like this:

<!-- Processed by Id:,v 1.164 2004/10/28 17:41:59 timbl Exp -->
<!--     using base file:/home/sean/doc/n3/foaf.n3-->

<rdf:RDF xmlns=""

    <Person rdf:about="#me">
    <homepage rdf:resource=""/>
    <name>Sean Hunter</name>
---  ---
---  ---
---  ---             Darkening of the Light. In adversity       
--------             It furthers one to be persevering.
---  ---

    <PersonalProfileDocument rdf:about="#this">
    <dc:title>Sean Hunter's FOAF file</dc:title>
    <maker rdf:resource="#me"/>
    <primaryTopic rdf:resource="#me"/>

...which I link from my homepage. Easy-peasy. I can validate it using the w3c rdf validator and it works just fine. Now I just need to add some friends. If you know me and want to be added to my foaf file, mail me at

Technorati tags: foaf rdf semantic web

Unless otherwise specified the contents of this page are copyright © 2015 Sean Hunter. This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.