In RDFS:
ex:someproperty
a rdf:Property ;
rdfs:domain ex:somedomainclass ;
rdfs:range ex:somerangeclass ;
In SHACL:
ex:someproperty
a rdf:Property, sh:PropertyShape ;
….?
Or not possible and need for:
ex:somepropertyShape1
a sh:PropertyShape ;
sh:targetSubjectsOf ex:someproperty ;
sh:class ex:somedomainclass .
ex:somepropertyShape1
a sh:PropertyShape ;
sh:targetObjectsOf ex:someproperty ;
sh:class ex:somerangeclass .
|
|
|||||||||||||||||
|
|
|||||||||||||||||
2.3 Property Shapes
A property shape is a shape in the shapes graph that is the subject of a triple that has
sh:pathas its predicate.
This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. TNO accepts no liability for the content of this e-mail, for the manner in which you use it and for damage of any kind resulting from the risks inherent to the electronic transmission of messages.
--
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to topbraid-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/ce25c5df596b4406a7311e9f27dfcb34%40tno.nl.
So in the end:
ex:somepropertyShape1
a sh:PropertyShape ;
sh:path ex:someproperty ;
sh:targetSubjectsOf ex:someproperty ;
sh:class ex:somedomainclass .
ex:somepropertyShape2
a sh:PropertyShape ;
sh:path ex:someproperty ;
sh:targetObjectsOf ex:someproperty ;
sh:class ex:somerangeclass .
the path and target subjectsof feel a bit double...
|
|
|
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/7A2451BE-9F50-4794-B063-6EE443F202A6%40topquadrant.com.
On 2 Apr 2020, at 15:34, 'Bohms, H.M. (Michel)' via TopBraid Suite Users <topbrai...@googlegroups.com> wrote:
So in the end:ex:somepropertyShape1a sh:PropertyShape ;sh:path ex:someproperty ;sh:targetSubjectsOf ex:someproperty ;sh:class ex:somedomainclass .ex:somepropertyShape2a sh:PropertyShape ;sh:path ex:someproperty ;sh:targetObjectsOf ex:someproperty ;sh:class ex:somerangeclass .the path and target subjectsof feel a bit double...
Dr. ir. H.M. (Michel) Böhms
Senior Data Scientist
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/feeb11ed39f24ab48502b96bd376592a%40tno.nl.
On Apr 2, 2020, at 10:06 AM, 'Bohms, H.M. (Michel)' via TopBraid Suite Users <topbrai...@googlegroups.com> wrote:In RDFS:ex:somepropertya rdf:Property ;rdfs:domain ex:somedomainclass ;rdfs:range ex:somerangeclass ;In SHACL:ex:somepropertya rdf:Property, sh:PropertyShape ;….?
Or not possible and need for:ex:somepropertyShape1a sh:PropertyShape ;sh:targetSubjectsOf ex:someproperty ;sh:class ex:somedomainclass .
ex:somepropertyShape1a sh:PropertyShape ;sh:targetObjectsOf ex:someproperty ;sh:class ex:somerangeclass .
ex:somepropertyShape1a sh:PropertyShape ;
sh:targetSubjectsOf ex:someproperty ;sh:class ex:somedomainclass .
Dr. ir. H.M. (Michel) Böhms
Senior Data Scientist
T +31888663107
M +31630381220
E michel...@tno.nl
Location
<image001.gif>
This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. TNO accepts no liability for the content of this e-mail, for the manner in which you use it and for damage of any kind resulting from the risks inherent to the electronic transmission of messages.
Would I only need the extra property shape complexity in case of the global property constraints like functional etc.?
|
|
|
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/6968267F-0626-494F-977E-F76F3FBCC156%40topquadrant.com.
On 2 Apr 2020, at 16:02, 'Bohms, H.M. (Michel)' via TopBraid Suite Users <topbrai...@googlegroups.com> wrote:Would I only need the extra property shape complexity in case of the global property constraints like functional etc.?
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/18c9d1a8767943108581af75aae53bbc%40tno.nl.
On Apr 2, 2020, at 11:02 AM, 'Bohms, H.M. (Michel)' via TopBraid Suite Users <topbrai...@googlegroups.com> wrote:
Would I only need the extra property shape complexity in case of the global property constraints like functional etc.?
Dr. ir. H.M. (Michel) Böhms
Senior Data Scientist
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/18c9d1a8767943108581af75aae53bbc%40tno.nl.
Thx, see in red.
Van: topbrai...@googlegroups.com <topbrai...@googlegroups.com>
Namens Irene Polikoff
Verzonden: Thursday, April 2, 2020 4:57 PM
Aan: topbrai...@googlegroups.com
Onderwerp: Re: [topbraid-users] shacl mapping question for domain/ranges
Further to David’s responses, some more below
On Apr 2, 2020, at 10:06 AM, 'Bohms, H.M. (Michel)' via TopBraid Suite Users <topbrai...@googlegroups.com> wrote:
In RDFS:
ex:someproperty
a rdf:Property ;
rdfs:domain ex:somedomainclass ;
rdfs:range ex:somerangeclass ;
In SHACL:
ex:someproperty
a rdf:Property, sh:PropertyShape ;
….?
No. A property is not a property shape
> ok, clear!
Or not possible and need for:
ex:somepropertyShape1
a sh:PropertyShape ;
sh:targetSubjectsOf ex:someproperty ;
sh:class ex:somedomainclass .
ex:somepropertyShape1
a sh:PropertyShape ;
sh:targetObjectsOf ex:someproperty ;
sh:class ex:somerangeclass .
A property shape must have sh:path
If you were to change the first property shape to
ex:somepropertyShape1
a sh:PropertyShape ;
ex:path ex:someproperty ;
sh:targetSubjectsOf ex:someproperty ;
sh:class ex:somedomainclass .
> ok
You would be saying that for each triple
?s ex:someproperty ?o
There must be a triple
?o a ex:somedomainclass.
> I do not get that..... it says: sh:targetSubjectsOf
> so why not: ?s ex:somedomainclass
Which is not what you want to say.
You would need to either use an inverse path on ex:someproperty - see https://www.w3.org/TR/shacl/#property-path-inverse or, alternatively, use sh:class ex:somerangeclass.
If you make these changes to your property shapes, you will get the validation to ensure the "right values" for the subjects and objects of triples. However, RDFS is not about validation, it is about inferencing. For inferencing you'd need to use SHACL rules.
Since the intention of SHACL constraints is different from the intention of RDFS domain/range, the literal translation (I think) you are trying to accomplish here would be into SHACL rules. On the other hand, if one were to reinterpret RDFS domain/range axioms into constraints, the most common way of doing this would be something like:
ex:somdomainclass a rdfs:Class, sh:NodeShape;
sh:property [sh:path ex:someproperty;
sh:class ex:somerangeclass].
> ok, I will do that! Solves also my next issue on unions of classes for domains (for each domain class I willspecify...)
And, as David mentioned, the common conversion patterns are described at https://spinrdf.org/shacl-and-owl.html. They are also implemented by TopBraid EDG. Conversion will be done automatically - see https://www.topquadrant.com/from-owl-to-shacl-in-an-automated-way/.
> Ok, guess the above is only needed in situations like functional etc. that is really for all doamins/ranges etc.
THx! Michel
Dr. ir. H.M. (Michel) Böhms
Senior Data Scientist
T +31888663107
M +31630381220
E michel...@tno.nl
Location
<image001.gif>
This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. TNO accepts no liability for the content of this e-mail, for the manner in which you use it and for damage of any kind resulting from the risks inherent to the electronic transmission of messages.
--
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to topbraid-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/ce25c5df596b4406a7311e9f27dfcb34%40tno.nl.
--
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
topbraid-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/46055CA9-E7F3-49F7-A58B-58979F11FA3A%40topquadrant.com.
I always use this link indeed but I might have overlooked examples/guides for dealing with rdfs:domain and rdfs:range ...
|
|
|
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/837E253A-4645-4289-AE0A-400285F1328E%40topquadrant.com.
One more
Suppose I have a property with ONLY a range specified
In that case I do need the PropertyShape right?
(since it becomes a universal constraint, not only in he context of some domain classes)
|
|
|
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/B6D998C7-EF9D-4B82-9AD3-83422EDE79AF%40topquadrant.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/2ee6397ea3064d78bb95289a2a967365%40tno.nl.
On Apr 2, 2020, at 11:25 AM, 'Bohms, H.M. (Michel)' via TopBraid Suite Users <topbrai...@googlegroups.com> wrote:
One moreSuppose I have a property with ONLY a range specifiedIn that case I do need the PropertyShape right?(since it becomes a universal constraint, not only in he context of some domain classes)
Dr. ir. H.M. (Michel) Böhms
Senior Data Scientist
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/da89311847274bbfbbe46231ca1bd23c%40tno.nl.