Re: owl:sameAs assertions in RDFa

On 01/04/2013 19:45, Gregg Kellogg wrote:
> On Apr 1, 2013, at 10:10 AM, Kingsley Idehen <kidehen@openlinksw.com> wrote:
>
>  > On 4/1/13 12:59 PM, Gregg Kellogg wrote:
>  >> On Apr 1, 2013, at 8:17 AM, Jeremy Tarling
> <jeremy.tarling@bbc.co.uk> wrote:
>  >>
>  >>> hello all
>  >>>
>  >>> I am trying to make an owl:sameAs assertion in some RDFa. I have
> the following code:
>  >>>
>  >>> <span rel="rnews:about"
> resource="http://www.bbc.co.uk/things/4c0ccb99-7042-49e5-bb44-338b540441eb#id">
>  >>>    <span rel="owl:sameAs"
> resource="http://dbpedia.org/resource/Buckinghamshire_County_Council"></span>
>  >>> </span>
>  >>>
>  >>> (I have declared the rnews and owl prefixes elsewhere in the doc)
>  >>>
>  >>> When I test it only the first statement (rnews:about bbc:thing) is
> being picked up by linked data extraction tools, the owl:sameAs to the
> corresponding dbpedia URI is being ignored. Can anyone tell me what I'm
> doing wrong here please?
>  >> Using my distiller [1], If I use the followiing input:
>  >>
>  >> <div prefix="rnews: http://iptc.org/std/rNews/2011-10-07#">
>  >>   <span rel="rnews:about"
> resource="http://www.bbc.co.uk/things/4c0ccb99-7042-49e5-bb44-338b540441eb#id">
>  >>      <span rel="owl:sameAs"
> resource="http://dbpedia.org/resource/Buckinghamshire_County_Council"></span>
>  >>   </span>
>  >> </div>
>  >>
>  >> I get the following output:
>  >>
>  >> @prefix owl: <http://www.w3.org/2002/07/owl#> .
>  >> @prefix rnews: <http://iptc.org/std/rNews/2011-10-07#> .
>  >>
>  >> <> rnews:about
> <http://www.bbc.co.uk/things/4c0ccb99-7042-49e5-bb44-338b540441eb#id> .
>  >>
>  >>
> <http://www.bbc.co.uk/things/4c0ccb99-7042-49e5-bb44-338b540441eb#id>
> owl:sameAs <http://dbpedia.org/resource/Buckinghamshire_County_Council> .
>  >>
>  >> Looks okay to me. Note "owl" is defined in the RDFa initial context.
>  >>
>  >> Gregg
>  >>
>  >> [1] http://rdf.greggkellogg.net/distiller
>  >
>  > Gregg,
>  >
>  > Why not share a complete HTML doc skeleton as this little episode
> could have a lot of future utility. If you don't mind, please just place
> the HTML doc you used at Web accessible location (URL).
>  >
>  > The owl:sameAs and rdfs:sameAs scenario has already spooked me :-)
>
> Sure, I put up the document at [1] and a hook to my distiller processing
> the document is at [2]. Note that this example is a simple case of
> chaining in RDFa, where the object of a parent element becomes the
> subject of the child element. This works only with @rel (or @rev) and
> not with @property, as it's considered an /advanced/ feature.
>
> Gregg Kellogg
> gregg@greggkellogg.net
>
> [1] http://greggkellogg.net/sameas-example.html
> [2]
> http://rdf.greggkellogg.net/distiller?format=turtle&in_fmt=rdfa&uri=http://greggkellogg.net/sameas-example.html
>
>
>  > Kingsley
>  >>
>  >>> JT
>  >>>
>  >>> --
>  >>> Jeremy Tarling
>  >>> Data Architect, BBC News
>  >>> Future Media News & Knowledge
>  >>> 4th floor New Broadcasting House
>  >>> London W1A 1AA
>  >>> tel: 07799 510 992
>  >>>
>  >>
>  >>
>  >>
>  >
>  >
>  > --
>  >
>  > Regards,
>  >
>  > Kingsley Idehen
>  > Founder & CEO
>  > OpenLink Software
>  > Company Web: http://www.openlinksw.com
>  > Personal Weblog: http://www.openlinksw.com/blog/~kidehen
>  > Twitter/Identi.ca handle: @kidehen
>  > Google+ Profile: https://plus.google.com/112399767740508618350/about
>  > LinkedIn Profile: http://www.linkedin.com/in/kidehen
>  >
>  >
>  >
>  >
>  >
>
>

Thanks Greg - yes that was my experience, I first tried to do this 
object-to-subject switch with @property and it failed, but @rel worked.

I'm having trouble with getting the owl: prefix declared with anything 
other than a local @xmlns on the <span>, which I suspect is not even legal.

So far I've tried the following approaches:

1. <span prefix="owl:http://www.w3.org/2002/07/owl#" rel="owl:sameAs" 
resource="http://dbpedia.org/resource/Buckinghamshire_County_Council"></span>

2. <span vocab="http://www.w3.org/2002/07/owl#" rel="sameAs" 
resource="http://dbpedia.org/resource/Buckinghamshire_County_Council"></span>

3. <span xmlns:owl="http://www.w3.org/2002/07/owl#" rel="owl:sameAs" 
resource="http://dbpedia.org/resource/Buckinghamshire_County_Council"></span>

In each case I have run against your RDF extractor using the example 
file here [1], only option 3 generates the desired sameAs statement.

I note your point above about owl being included in the initial RDFa 
context. Perhaps I am breaking that by declaring xmlns:rnews in the 
document's <html> element

JT

[1] http://www.topdrawersausage.net/rnews-example.html

Received on Monday, 1 April 2013 19:25:06 UTC