W3C home > Mailing lists > Public > public-cwm-talk@w3.org > October to December 2008

Re: serialising literal subjects to rdf/xml

From: Story Henry <henry.story@bblfish.net>
Date: Thu, 6 Nov 2008 12:44:50 +0100
Cc: public-cwm-talk@w3.org
Message-Id: <4CFE8FCA-8F15-4AC4-9CB8-BB30470CC47A@bblfish.net>
To: Tim Berners-Lee <timbl@w3.org>

(Sorry for taking so long to reply, I just realized my mail client had  
stopped fetching my mail for a few days now.)

On 4 Nov 2008, at 04:15, Tim Berners-Lee wrote:
> I agree with the technique, except with using owl:sameAs.
>
> What you serialize with owl:sameAs  is a different graph.
> RDF systems don't *have* to smush on owl:sameAs.
>
> I propose using a dummy predicate rdf:is which is NEVER put really  
> in the graph,it is just part of the syntax.  It is used for making  
> the same node from a bnode and a symbol be the same node in the graph.
>
>
> The equivalent in N3 was :- but I now prefer  == .  This can then  
> be  used in
>
> joe :mother [ == agnes; mother andrea ].

I would like == too btw. That would make writing human readable N3  
much easier, as it can help
cluster related triples inside a [ ] as you show.


But in this case I was proposing the rewriting for when one wants to  
export a graph to rdf/xml. It was spurred by a recent post to this  
list where someone had encountered a problem serialising an RDF graph  
to rdf/xml . I don't think there is a way talk of a subject literal in  
rdf/xml. cwm does produce some output, as shown below, but this is not  
accepted by the w3c rdf validator service
	http://www.w3.org/RDF/Validator/
So for rdf/xml outputs I think the only solution is to produce the  
semantically equivalent graph that uses the owl:sameAs rewriting.

$ cwm test/crypto/access-elisa.cert --rdf

<rdf:RDF xmlns="http://www.w3.org/2000/10/swap/test/crypto/acc.n3#"
     xmlns:acc="http://www.w3.org/2000/10/swap/test/crypto/acc.n3#"
     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">

     <rdf:Description rdf:about="     @prefix : &#60;http://www.w3.org/2000/10/swap/test/crypto/acc.n3# 
&#62; .&#10;    &#10;     
&#34 
;&#34 
;&#34 
;&#10 
;NjU1MzcKCjEzMTc4NTkyNzM4NDYzNTYyODExOTYwODA0MzI5ODc4MjcxMjA0ODEwMTg0MzAwNzUy 
&#10 
;NDA2MDkyNjc5MzA3MTg1NjYyMjA0NjA4ODY3NjU4MzIwMzkwNzU4NjM1ODQ1ODExMTk4MjgwMTAz 
&#10 
;MDI2NDM5MzY2ODg1MTE0MTMwMDg5MjQzMzEwNTI1OTMzMjQ4ODc2NTIxMDkwMzExNjk2ODMwMjcx 
&#10 
;ODAyNTAwNTgxODgzODc2ODM3NjczNzY1NzIyNjczMDk3MjkyMTI5MzI2NjIwMTQ1MTQwMzA0Nzcx 
&#10 
;OTA3MTg5MDc4OTE1NjY3NjAwNzA3NTcyMDU5MTcxMDg1MzA1ODY5MzQ4MDU1MTY1OTIxMDEwOTIy 
&#10 
;NjQ0MjI1MDc3NTI2MTMxNjY5ODk0NjExMjUxMzI1OQ 
=3D=3D&#10;&#34;&#34;&#34;      
a :MemberKey;&#10;         :authorityName  
&#34;Elisa&#34;;&#10;         :junk  
&#34;327462sjsdfjsakdhfkjsafd32164321&#34; .&#10;    &#10;">
         <endorsement rdf:parseType="Resource">
             <key>
NjU1MzcKCjE0NTExMjQwNjAwMjk1MjUyOTY4ODUzOTAzNjM4NDY2NDQ5MzIwODQ2MTc3NjEyMDQ4
NTIwNDY4NDg1NzM2MjQzNDgzNTc5NzY1NDY3ODkxMTg5NDg1NjY0OTM0NDkyMTU1Mjg4MTgxMjA3
MDc1Mzc4NTY5MTA5MDgwMzExMjU2MjU5ODA4ODg0MzMyMTcwMjY3MTkwMjMzNjI5NTAxOTI3NTMz
NzY0MjI0MjQ3MzgzODcyNTM1NDMwMTc2NjcwMTIxOTk3MjY4OTU1MzY0MjU1ODM1MDkwNjQ3NTE0
OTIzNjg5Mzc2Mzc0ODQwMjY1NzY0Njc3MzgzMDg0NTk1MTg2ODM4MzUxOTYzMzQzODI0MjIzNjE1
OTE3OTM3NDgxMDM3Mjk5OTk2NDQxMjAwNzM2MjY1Mw=3D=3D
</key>
             <signature>
OTc5OTQ3ODE1Mjk3MzMzNTY1NTYzNzcxMTk4MTQ4MjE1ODgzMDI1MTcyNDQ1ODgzMzcxNTY0MTU3
Nzk4OTc2ODEwMDYxNTg2NzQ3ODY5MTA3NDM4Njc1OTM4ODU1Nzg1NTk2NzU5MDYwMDQxOTE4OTMx
MDYwMjg5MDE2NzA5MTk0MTI3MDI1NzcwMTgwODcxNDY1Mzk3NTYyNzQ1NDI4NTY0Mjg3MDgwMzk5
NzEyMTk3MjYzNDU3NTg0MTExNDU3MjI3MTMyNDk1NTI5MzAyMzA3OTkzNjk1OTE3Mjk2NTY3ODQ2
NTkwNTUxODA3MTczNDc1MjYyOTc3MzY3OTM1OTc4Nzc3MDQwMTQ2NzAzMzc3MTI4NTU3NTQ3MzU2
OTczMDU2MDQwMDA5ODk4NjkyOTQ1NTU=3D
</signature>
         </endorsement>
     </rdf:Description>
</rdf:RDF>





> etc.
>
>
> Tim
>
> On 2008-11 -03, at 08:26, Story Henry wrote:
>
>>
>> Suggestion:
>>
>> It should be easy to allow any N3 graph with literal subjects to be  
>> serialised to rdf/xml, Turtle or Ntriples.
>> Use the following method:
>>
>> replace
>>     "subject" relation object .
>> with
>>     subjectUri owl:sameAs "subject";
>>                relation object .
>>
>> That should allow any such graph to be serialised to rdf/xml .
>>
>> 	Henry
>>
>>
>> Home page: http://bblfish.net/
>>
>
>
Received on Thursday, 6 November 2008 11:45:37 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 6 November 2008 11:45:38 GMT