Re: Simplification of scopes section (see also ISSUE-148)

On 05/14/2016 11:44 AM, Karen Coyle wrote:
> On 5/14/16 10:05 AM, Irene Polikoff wrote:
>> To me, this sounds like a question about what it means for a shape not to
>> have a scope.
>> One answer could be - such a shape is ignored. A shape is not evaluated
>> against any nodes unless there is a scope.
>> Another answer could be - it is then becomes applicable everywhere, meaning
>> that any node in the data graph becomes a focus node for such a shape.
>> What is the current approach?
> The document does not address this. Therefore, we do not have one. - kc

The SHACL spec certainly does not make it clear how validation works.  My
recent suggestions  on changes to the terminology section include some aspects
of how shapes, scopes, filters, and constraints all work together, but there
are other places in the spec that are unclear.

For example,

"2.1 Scopes
Scopes define the set of focus nodes for a shape"

makes it look like the nodes that satisfy the scopes of a shape are the only
nodes that are ever validated by the shape.  This is not correct at all.

There is wording in the spec that does attempt to give the correct view of
shapes and scopes, however.

"When multiple scopes are provided in a shape, the scope of a shape is the
union of all focus nodes produced by these scopes."

Although this could be stated much better, it appears to be trying to say that
each node in the data graph that satisfies any of the scopes of a shape is
considered when validating against the shape.  If a shape has no scopes then
no validation is initiated by that shape.

This does not mean that shapes without scopes are useless.   Shapes that are
mentioned in other shapes might not initiate validation, but they can be used
during validation initiated by the other shape.


Received on Saturday, 14 May 2016 19:02:23 UTC