Re: ISSUE-133 syntax simplifications & regularizations

On Tue, May 10, 2016 at 6:55 PM, Peter F. Patel-Schneider <
pfpschneider@gmail.com> wrote:

> OK, no more sh:defaultValueType.  Good.
>
> How does the syntax of constraints work now?
>
>
> Can any triples be removed from the following RDF graph without changing
> its validation behaviour?  If so, which ones?
>
> @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
> @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
> @prefix sh: <http://www.w3.org/ns/shacl#> .
> @prefix ex: <http://example.com/ns#> .
>
> ex:s1 a sh:Shape ;
>  sh:scopeClass ex:Foo ;
>  sh:node [ a sh:NodeConstraint ;
>            sh:nodeKind sh:IRI ] ;
>  sh:property [ a sh:PropertyConstraint ;
>                sh:predicate ex:p ;
>                sh:class ex:Bar ] .
>
>
imo this shapes graph is valid and  both type triple can be removed


>
> Does the following RDF graph contain a syntactically-valid SHACL shape?  If
> not, why not?
>
> @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
> @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
> @prefix sh: <http://www.w3.org/ns/shacl#> .
> @prefix ex: <http://example.com/ns#> .
>
> ex:NodeConstraint rdfs:subClassOf sh:NodeConstraint .
> ex:subClassOf rdfs:subPropertyOf rdfs:subClassOf .
> ex:PropertyConstraint ex:subClassOf sh:PropertyConstraint .
>
> ex:s2 a sh:Shape ;
>  sh:scopeClass ex:Foo ;
>  sh:node [ a ex:NodeConstraint ;
>            sh:nodeKind sh:IRI ] ;
>  sh:property [ a ex:PropertyConstraint ;
>                sh:predicate ex:p ;
>                sh:class ex:Bar ] .
>

I think this shapes graph is valid as well but other may correct me if I am
wrong but let me explain why first
 - I believe  we still need to say that (sh:NodeConstraint,
sh:PropertyConstraint, sh:InversePropertyConstraint, sh:SparqlConstraint)
are pairwise disjoint.
 - As long as the above rule is not violated we are fine
 - we do not say that values of sh:node / sh:property must not be instances
of other classes only that they must be instances of sh:NodeConstraint /
sh:PropertyConstraint, so a shacl engine can assign the proper types even
without any inferencing at all

if on the other hand you stated
ex:PropertyConstraint ex:subClassOf sh:InversePropertyConstraint .
this would be problematic but I think we should avoid such (edge) cases


>
> peter
>
>
>
> On 05/10/2016 07:36 AM, Dimitris Kontokostas wrote:
> > After a quick offline discussion with Holger we would like to propose
> some
> > work towards syntax simplification
> >
> > The proposal has 2 aspects that go together
> > 1. we remove the sh:defaultValueType from SHACL (Peter also had concerns
> with
> > this - see issue-128)
> > 2. we simplify sh:constraint in the following ways
> >
> > a. sh:constraint is renamed to sh:node (other names welcome) and may
> have only
> > values of sh:NodeConstraint type
> > b. native sparql constraints (which could be used inside sh:constraint)
> are
> > now declared separately using a new property sh:sparqlConstraint that
> allows
> > only sh:SparqlConstraints
> >
> > We believe this is a simplification everyone will like and would like to
> put
> > it in the agenda for the next telco. Any comments are welcome
> >
> > rational for this change is the discussion for wording section 2.3.
> > sh:defaultValueType was complicating things and one of the reasons it was
> > introduced is to disambiguate the values of sh:constraint.
> > With this change every predicate can have only one possible type now
> > and sh:defaultValueType is no longer needed
> >
> > Best,
> > Dimitris
> >
> > --
> > Dimitris Kontokostas
> > Department of Computer Science, University of Leipzig & DBpedia
> Association
> > Projects: http://dbpedia.org, http://rdfunit.aksw.org,
> > http://http://aligned-project.eu <http://aligned-project.eu/>
> > Homepage:http://aksw.org/DimitrisKontokostas
> > Research Group: AKSW/KILT http://aksw.org/Groups/KILT
> >
>
>


-- 
Dimitris Kontokostas
Department of Computer Science, University of Leipzig & DBpedia Association
Projects: http://dbpedia.org, http://rdfunit.aksw.org, http://
http://aligned-project.eu
Homepage:http://aksw.org/DimitrisKontokostas
Research Group: AKSW/KILT http://aksw.org/Groups/KILT

Received on Tuesday, 10 May 2016 20:17:26 UTC