W3C home > Mailing lists > Public > www-rdf-interest@w3.org > January 2002

how does existing RDF software handle this datatypes test?

From: Dan Connolly <connolly@w3.org>
Date: 30 Jan 2002 11:03:59 -0600
To: RDF Interest <www-rdf-interest@w3.org>, RDF Logic <www-rdf-logic@w3.org>
Message-Id: <1012410239.17946.42.camel@dirk>
There's a lot to read about TDL and S,
http://lists.w3.org/Archives/Public/www-rdf-interest/2002Jan/0164.html
but I think it can be summarized with the following
test case. If you develop (or use) any RDF software,
please try it out on this test case and report
your findings.

Consider this RDF document:

<rdf:RDF
xmlns="file:/home/connolly/w3ccvs/WWW/2000/10/swap/test/dt10-premise.n3#"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
    xmlns:ex="http://example/vocab#"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">

    <rdf:Description>
        <rdf:type rdf:resource="#Film"/>
        <dc:title>10</dc:title>
    </rdf:Description>

    <rdf:Description rdf:about="#mary">
        <ex:age>10</ex:age>
    </rdf:Description>
</rdf:RDF>

If you read RDF/N3, and you don't mind some ommitted
prefix declarations, you might find this short version
easier to grok:
  _:f rdf:type <#Film> .
  _:f dc:title "10" .
  <#mary> ex:age "10" .

Suppose I asked you:
	does that document say that
	there's something with a dc:title?
I hope you'd say: yes, of course.
Now... suppose I ask:
	whatever that title is, let's call it X.
	Does that document also say that there's
	something with ex:age of that same X?

If you have any sort of RDF API or query language or
any sort of software in which this question can be posed,
would you please ask your implementation and tell
us its answer right now?

[[for those of you that have followed the (unapproved)
entailment test work,
  http://www.w3.org/2000/10/rdf-tests/rdfcore/#not_approved
you can use this as an entailment test:
premise:
  http://www.w3.org/2000/10/swap/test/dt10-premise.rdf
conclusion:
  http://www.w3.org/2000/10/swap/test/dt10-conc.nt

If you use cwm, you can use this test-driver:
  cwm http://www.w3.org/2000/10/swap/test/datatype10.n3 --think
]]

The TDL position (as I understand it) is: no...
That document doesn't say that Mary's age is
the same as the Film's title. There's probably
a range constraint on ex:age that says it's
an integer; not a numeral, but a real integer.
The film's title is probably a numeral.
There are certainly interpretations in which
they denote different things; hence the conclusion
is not valid.

The S position is: yes, that document says
mary's age is "10" and the Film's title is "10".
The conclusion is valid in all interpretations.
The range of the age property is most likely
a numeral, not a number. If you want an age
property whose range is a number, you can have
that, but it's a distinct property; let's
say exV:age. and you need to write:

	<ex:age rdfdt:decimal="10"/>

where rdfdt:decimal expands to the name we
choose for the mapping from decimal values
to decimal literals.

ACKS: Sergey made up this example.
http://lists.w3.org/Archives/Public/w3c-rdfcore-wg/2002Jan/0293.html
or... hmm... that's not quite the same...
maybe Brian made up this example. Anyway...
I got the gist of the test case from
somebody else.

-- 
Dan Connolly, W3C http://www.w3.org/People/Connolly/
Received on Wednesday, 30 January 2002 12:40:34 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:51:52 GMT