The triple "Person:X is:this Man:X"
has these encodings (from a semantic wiki that requires all
its pagenames to contain a 'type' prefix).
Draw your own conclusions about each encoding but to me Turtle is
superior, followed by XML, and wiping up the rear would be JSON,
because JSON has no text entity support unlike the other two. And
so, fwiw, I think the claim JSON is a 'lightweight' protocol is
somewhat unfounded plus I'm not crazy about an English-only
protocol. Feel free to correct me if I've missed anything here.
thanks/jmc
1. Striped RDF XML
<!ENTITY rdf "http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<!ENTITY wiki
"http://www.mysemanticwiki.com/wiki/">
<!ENTITY is "http://www.mysemanticwiki.com/ontology/is.rdf#">
<!ENTITY nouns "http://www.mysemanticwiki.com/ontology/Nouns.rdf#">
<rdf:RDF xml:ns="&nouns;"
xmlns:rdf="&rdf;"
xmlns:is="&is;">
<Person rdf:id="&wiki;Person:X">
<is:this rdf:resource="&wiki;Man:X"/>
</Person>
</rdf:RDF>
2. Turtle
@prefix rdf:
<http://www.w3.org/1999/02/22-rdf-syntax-ns#>
@prefix wiki: <http://www.mysemanticwiki.com/wiki/>
@prefix is: <http://www.mysemanticwiki.com/ontology/is.rdf#>
@prefix : <http://www.mysemanticwiki.com/ontology/Nouns.rdf#>
wiki:Person:X
rdf:type :Person ;
is:this wiki:Man:X
.
3. JSON
{ "http://www.mysemanticwiki.com/wiki/Person:X"
:
{ "http://www.w3.org/1999/02/22-rdf-syntax-ns#type"
:
[ { "value" : "http://www.mysemanticwiki.com/ontology/Nouns.rdf#Person",
"type" : "uri"
}
]
},
{ "http://www.ubuntuwiki.co.za/ontology/is.rdf#this"
:
[ { "value" : "http://www.mysemanticwiki.com/wiki/Man:X",
"type" : "uri"
}
]
}
}
4. Semantic Wiki (bonus!)
<mediawiki xmlns="http://www.mediawiki.org/xml/export-0.5/">
...
<page>
<title>Person:X</title>
<revision>
<text>[[rdf:type :: Person]]
[[is:this :: Man:X ]]
</text>
</revision>
</page>
</mediawiki>
|
_________________________________________________________________
Message Archives: http://ontolog.cim3.net/forum/ontolog-forum/
Config Subscr: http://ontolog.cim3.net/mailman/listinfo/ontolog-forum/
Unsubscribe: mailto:ontolog-forum-leave@xxxxxxxxxxxxxxxx
Shared Files: http://ontolog.cim3.net/file/
Community Wiki: http://ontolog.cim3.net/wiki/
To join: http://ontolog.cim3.net/cgi-bin/wiki.pl?WikiHomePage#nid1J (01)
|