W3C home > Mailing lists > Public > public-rdf-wg@w3.org > May 2012

Re: named graphs in HTML

From: Ivan Herman <ivan@w3.org>
Date: Wed, 9 May 2012 17:04:17 +0200
Cc: public-rdf-wg <public-rdf-wg@w3.org>
Message-Id: <7E7A0B16-D526-4EEA-A651-61F95919E5FF@w3.org>
To: Sandro Hawke <sandro@w3.org>

On May 9, 2012, at 16:34 , Sandro Hawke wrote:
> 
> Option 1:
> 
> At http://example.com/doc1 we say: 
> 
>        <html>
>        ...
>        <script type="text/trig">
>        @prefix eg: <http://example.com/ns>.
>        <#section> { eg:a eg:b eg:c }
>        </script>
>        ...
>        </html>
> 
> Option 2:
> 
> 
> At http://example.com/doc1 we say: 
> 
>        <html>
>        ...
>        <script type="text/turtle" id="section">
>        @prefix eg: <http://example.com/ns>.
>        eg:a eg:b eg:c.
>        </script>
>        ...
>        </html>
> 
> Okay, yeah, I see your point.   Mechanically, option 1 is okay, and
> procedurally, it's much simpler.
> 
> My preference for option 2 comes from my sense of Web Architecture, that
> id attributes simply continue the URL after the hash.   The URL foo#bar,
> if "foo" is an HTML document", is the *name* of the section of "foo"
> with the id "bar".   

I agree. It would be better... and we had similar discussions in the RDFa group, ie, whether the @id attribute would be used or not. However, practice went against us: HTML authors, who do not really know too much about these issues, would be bound to make a mistake and get unwanted consequences (so RDFa, for that reason, does _not_ use @id either).

Ivan


> But whatever.  This wouldn't be the first time
> people chose expediency of architectural purity.
> 
>     -- Sandro
> 
> 
>> Ivan
>> 
>> 
>>> 
>>> It would also be nice to have a way to say one wants the triples to
>>> *also* go into the default graph -- so if what you're doing is graph
>>> annotation you don't have to repeat all the triples in the annotated
>>> graph.  Maybe class="included" or something; I'm not sure how the
>>> namespaces of HTML classes works these days.
>>> 
>>> I know this touches on something Steve said yesterday about getting
>>> quads when you're expecting triples; I'll reply to that separately.
>>> 
>>>    -- Sandro
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>> 
>> 
>> ----
>> Ivan Herman, W3C Semantic Web Activity Lead
>> Home: http://www.w3.org/People/Ivan/
>> mobile: +31-641044153
>> FOAF: http://www.ivan-herman.net/foaf.rdf
>> 
>> 
>> 
>> 
>> 
>> 
> 
> 


----
Ivan Herman, W3C Semantic Web Activity Lead
Home: http://www.w3.org/People/Ivan/
mobile: +31-641044153
FOAF: http://www.ivan-herman.net/foaf.rdf
Received on Wednesday, 9 May 2012 15:01:32 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 16:25:48 GMT