W3C home > Mailing lists > Public > public-data-shapes-wg@w3.org > March 2015

Re: a SHACL specification based on SPARQL

From: Arthur Ryman <arthur.ryman@gmail.com>
Date: Thu, 19 Mar 2015 12:58:41 -0400
Message-ID: <CAApBiO=L+nofyDNqGVq8vSohgi8np=CuYFrvzK8uCusZ2ckEWw@mail.gmail.com>
To: Richard Cyganiak <richard@cyganiak.de>
Cc: "public-data-shapes-wg@w3.org" <public-data-shapes-wg@w3.org>

I hope not :-)

My point is that in order to produce answers that users will expect,
we need to go beyond entailment. In the example the the RDF graph
contains a term from OWL so users should use OWL entailment. However,
OWL entailment will simply add more triples, e.g.:

ex:Darth owl:sameAs ex:Anakin .

However, the intention of the user is to assert that ex:Darth and
ex:Anakin denote the same resource. So from the user viewpoint the
graph does not violate the cardinality constraint. However, if we
naively count triples, then the graph violates the cardinality

This discord is very similar to the one we encounter with multiple
lexical forms for a given literal value. For example, suppose the
property ex:numberOfWheels has cardinality of exactly-one. Consider
the following graph:

ex:MyUnicycle ex:numberOfWheels "1"^^xsd:integer .
ex:MyUnicycle ex:numberOfWheels "01"^^xsd:integer .

A user might expect this to be valid since the two lexical forms
correspond to the same literal value. However, if we naively count
triples then the graph is invalid. Peter has repeatedly raised this

The simple thing for SHACL to do is naive triple counting. However,
this might cause a problem in some real-world situations. I think we'd
need a way for users to specify the behavior they want. For example,
we could introduce a canonical form function to pick a unique
representative for each IRI or literal.

-- Arthur

On Thu, Mar 19, 2015 at 7:00 AM, Richard Cyganiak <richard@cyganiak.de> wrote:
> Arthur,
>> On 17 Mar 2015, at 20:00, Arthur Ryman <arthur.ryman@gmail.com> wrote:
>> Concerning RDFS, I'd prefer to see SHACL specified purely in terms of
>> graphs, i.e. what you get after entailment.
> […]
>> For example, if I specify that ex:hasFather is
>> zero-or-one, and have the following:
>> ex:Luke ex:hasFather ex:Anakin .
>> ex:Luke ex:hasFather ex:Darth .
>> ex:Anakin owl:sameAs ex:Darth .
>> then there should be no violation.
> Aren’t you contradicting yourself here?
> In the owl:sameAs example, the graph clearly contains two ex:hasFather triples for ex:Luke. If ex:hasFather is zero-or-one, and SHACL is specified purely in terms of graphs, then that has to be a violation.
> Richard
Received on Thursday, 19 March 2015 16:59:14 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:30:18 UTC