Re: [topbraid-users] "allValuesfrom" Function Missing in SHACL file

2020-07-07 Thread Irene Polikoff


> On Jul 8, 2020, at 12:04 AM, Emily Zhang  wrote:
> 
> Hi Irene,
> Great suggestions on creating a property for "Diagnosis". I've done that but 
> I am not exactly sure: 1) If I want to infer a patient has Melanoma, should 
> Melanoma be an instance under the property "Diagnosis”?

What do you mean by “under”. How can an instance be under a property?

> 2) You mentioned "I need to run it on a graph that has data and it must 
> include your model and rules.", I am not really familiar with the concept 
> "graph" in the Top Braid Composer.

https://topbraidcomposer.org/html/NamedGraphsAndBaseURIs.htm 

> 3) For the inferred results, since you mentioned I don't have to use 
> tosh:value for sparql in this case, I was expecting to "run inference" 
> against the instance of "Patient" and got a returned label for " Melanoma"? 
> But there was still nothing returned. The inference run successfully,

Not sure what is going wrong for you.

> 4) I even tried to add sparql query attached below, the "execute SPARQL" 
> button was grey somehow. 
> Here is the source code I used: 
> p3point_validation:Patient
> 
>   rdf:type owl:Class ;
> 
>   rdf:type sh:NodeShape ;
> 
>   rdfs:subClassOf rdfs:Resource ;
> 
>   sh:rule [
> 
>   rdf:type sh:TripleRule ;
> 
>   sh:condition [
> 
>   sh:property [
> 
>   sh:path 
>  ;
> 
>   sh:in (
> 
>   p3point_validation:Atypical
> 
>   p3point_validation:Asymmetry
> 
>   p3point_validation:Blue_white_structure
> 
> ) ;
> 
>   sh:maxCount 3 ;
> 
>   sh:minCount 2 ;
> 
> ] ;
> 
> ] ;
> 
>   sh:object p3point_validation:Melanoma ;
> 
>   sh:predicate rdf:type ;
> 
>   sh:subject sh:this ;
> 
> ] ;
> 
> .
> 
> 

How do your data triples look like?

Is your data graph separate from the graph containing your model and the rule 
or are they together? If they are separate, does your data graph owl:imports 
your shapes graph?

https://topbraidcomposer.org/html/Imports_Panel.htm 


> Here is the SPARQL query:
> SELECT *
> 
> WHERE {
> 
>   ?Patient a schema: Patient .
> 
> (?Patient schema: Diagnosis) tosh:values ?Diagnosis .
> 
> }
> 
> 
> 
> Appreciate a lot!
> 
> Best,
> 
> Emily
> 
> 在 2020年6月30日星期二 UTC-5下午5:34:47,Irene Polikoff写道:
> Yes, if you are in Composer, then clicking on Run Inferencing would normally 
> run SHACL rules. You will need to run it on a graph that has data and it must 
> include your model and rules.
> 
> I do not know if Composer will run Property Value rules when Run Inferencing 
> is pressed. Holger will know.
> 
> The whole point with Property Value rules is that values are calculated 
> dynamically at query time, they are not stored any where. When you press Run 
> Inferencing, however, inferred triples actually get materialized in a graph.
> 
> The page I sent you has a section entitled Use of Inferred Values using 
> SPARQL. This is for dynamic inferencing.
> 
> If you Run Inferencing and get triples persisted/materialized, then you can 
> query for them as you would for any other triple - nothing special is 
> required.
> 
>> On Jun 30, 2020, at 5:47 PM, Emily Zhang > wrote:
>> 
>> Thanks, Irene! It's a great suggestion to create a new property for 
>> diagnosis:Melanoma. I will try to add sh:values for the new property. Just 
>> to clarify, I was using TopBraid Composer instead of EDG, and according to 
>> the tutorial, I should "press the Run Inferences button to materialize the 
>> inferences." 
>> For the materials you've provided so far, I've only seen the example GraphQL 
>> query to fetch the results. But I guess that's okay since I found another 
>> type of file in composer that I can create which is "GraphQL/SHACL" file. I 
>> could try to move my source code, write a GraphQL to query the results and 
>> press the Run Inferences button. Hopefully I can get the returned label 
>> "Melanoma" for that "patient".
>> 
>> 
>> 在 2020年6月30日星期二 UTC-5下午1:10:42,Irene Polikoff写道:
>> Emily,
>> 
>> If you have a shape like this
>> 
>>> p3point_validation:Patient a owl:Class, sh:NodeShape
>>> sh:rule [
>>> a sh:TripleRule ;
>>> sh:subject sh:this;
>>> sh:predicate rdf:type ;
>>> sh:objectp3point_validation:Melanoma;
>>> 
>>> sh:condition [
>>>   sh:property [
>>> 
>>>   sh:path p3point_validation:point_dermfeatures ;
>>> 
>>>   sh:in (
>>> 
>>>   p3point_validation:Atypical
>>> 
>>>   p3point_validation:Asymmetry
>>> 
>>>   p3point_validation:Blue_white_structure
>>> 
>>> ) ;
>>> 
>>>   sh:minCount 2 ;
>>> 
>>> ] ;
>>> ]
>>> ]
>>> 
>> 
>> 
>> And you have

Re: [topbraid-users] "allValuesfrom" Function Missing in SHACL file

2020-07-07 Thread Emily Zhang
Hi Irene,
Great suggestions on creating a property for "Diagnosis". I've done that 
but I am not exactly sure: 1) If I want to infer a patient has Melanoma, 
should Melanoma be an instance under the property "Diagnosis"? 2) You 
mentioned "I need to run it on a graph that has data and it must include 
your model and rules.", I am not really familiar with the concept "graph" 
in the Top Braid Composer. 3) For the inferred results, since you mentioned 
I don't have to use tosh:value for sparql in this case, I was expecting to 
"run inference" against the instance of "Patient" and got a returned label 
for " Melanoma"? But there was still nothing returned. The inference run 
successfully, 4) I even tried to add sparql query attached below, the 
"execute SPARQL" button was grey somehow. 
Here is the source code I used: 

p3point_validation:Patient

  rdf:type owl:Class ;

  rdf:type sh:NodeShape ;

  rdfs:subClassOf rdfs:Resource ;

  sh:rule [

  rdf:type sh:TripleRule ;

  sh:condition [

  sh:property [

  sh:path 
 ;

  sh:in (

  p3point_validation:Atypical

  p3point_validation:Asymmetry

  p3point_validation:Blue_white_structure

) ;

  sh:maxCount 3 ;

  sh:minCount 2 ;

] ;

] ;

  sh:object p3point_validation:Melanoma ;

  sh:predicate rdf:type ;

  sh:subject sh:this ;

] ;

.
Here is the SPARQL query:

*SELECT* *

*WHERE* {

?Patient a schema: Patient .

(?Patient schema: Diagnosis) *tosh:values* ?Diagnosis .

}


Appreciate a lot!

Best,

Emily
在 2020年6月30日星期二 UTC-5下午5:34:47,Irene Polikoff写道:
>
> Yes, if you are in Composer, then clicking on Run Inferencing would 
> normally run SHACL rules. You will need to run it on a graph that has data 
> and it must include your model and rules.
>
> I do not know if Composer will run Property Value rules when Run 
> Inferencing is pressed. Holger will know.
>
> The whole point with Property Value rules is that values are calculated 
> dynamically at query time, they are not stored any where. When you press 
> Run Inferencing, however, inferred triples actually get materialized in a 
> graph.
>
> The page I sent you has a section entitled *Use of Inferred Values using 
> SPARQL*. This is for dynamic inferencing.
>
> If you Run Inferencing and get triples persisted/materialized, then you 
> can query for them as you would for any other triple - nothing special is 
> required.
>
> On Jun 30, 2020, at 5:47 PM, Emily Zhang > 
> wrote:
>
> Thanks, Irene! It's a great suggestion to create a new property for 
> diagnosis:Melanoma. I will try to add sh:values for the new property. Just 
> to clarify, I was using TopBraid Composer instead of EDG, and according 
> to the tutorial, I should "press the Run Inferences button to materialize 
> the inferences." 
> For the materials you've provided so far, I've only seen the example 
> GraphQL query to fetch the results. But I guess that's okay since I found 
> another type of file in composer that I can create which is "GraphQL/SHACL" 
> file. I could try to move my source code, write a GraphQL to query the 
> results and press the Run Inferences button. Hopefully I can get the 
> returned label "Melanoma" for that "patient".
>
>
> 在 2020年6月30日星期二 UTC-5下午1:10:42,Irene Polikoff写道:
>>
>> Emily,
>>
>> If you have a shape like this
>>
>> p3point_validation:Patient a owl:Class, sh:NodeShape
>>> sh:rule [
>>> a sh:TripleRule ;
>>> sh:subject sh:this;
>>> sh:predicate rdf:type ;
>>> sh:objectp3point_validation:Melanoma;
>>>
>> sh:condition [
>>>   sh:property [
>>>
>>>   sh:path p3point_validation:point_dermfeatures ;
>>>
>>>   sh:in (
>>>
>>>   p3point_validation:Atypical
>>>
>>>   p3point_validation:Asymmetry
>>>
>>>   p3point_validation:Blue_white_structure
>>>
>>> ) ;
>>>
>>>   sh:minCount 2 ;
>>>
>>> ] ;
>>> ]
>>> ]
>>>
>>
>>
>> And you have an instance of p3point_validation:Patient with some of the 
>> listed values for the p3point_validation:point_dermfeatures property, you 
>> will get this inference - provided that the patient has at least 2 values 
>> for the property.
>>
>> I do not understand what you meant by "it only provided examples for the 
>> EDG version”. EDG version of what? 
>>
>> EDG performs these inferences so yes, everything you see is for EDG.
>>
>> How are you running the inferences? You need to go to the Transform tab 
>> in EDG to execute.
>>
>> If you wanting to invoke inference execution programmatically, then, as 
>> explained in the slides, you need to script it. You will need to write a 
>> script that will call the SPARQLMotion module - again, explained in the 
>> slides. This would be either SWP or SPAR

Re: [topbraid-users] Q: EDG - How does display property shapes?

2020-07-07 Thread Holger Knublauch

Just to add a tiny bit of info in case it's not clear:

If you have multiple property shapes on the same property (anywhere in 
the superclass hierarchy) the semantics of them will be merged together. 
It doesn't matter if the PropertyShape instance is different - the 
constraints are simply all treated the same. This also means all 
sh:class constraints would be checked together and the instances need to 
fulfill them all. This usually only works if there is a subclass 
relationship between those.


Holger


On 8/07/2020 13:47, Irene Polikoff wrote:

Hi Tim,

It would be highly irregular to create, for the same class/node shape, 
multiple property shapes with the same path and give them different 
sh:name. It would be misleading as, in the data, these will be the 
same properties.


Further, what you are defining below is contradictory


pgont:FVNR
  a edg:CustomAssetClass ;
  a sh:NodeShape ;
  edg:acronym "FVNR" ;
  edg:description "To Be Determined" ;
  rdfs:isDefinedBy  ;
  rdfs:label "FVNR" ;
  rdfs:subClassOf pgont:ElectricMotorStarter ;
  sh:property pgont:FVNR_Sts_Overload-output ;
  sh:property pgont:FVNR_Sts_Running-output ;
.
pgont:FVNR_Sts_Overload-output
  a sh:PropertyShape ;
  sh:path edg:output ;
  rdfs:isDefinedBy  ;
  sh:class pgont:FaultCondition ;
  sh:description "FF: Control Overload" ;
  sh:group edg:TraceableGroup ;
  sh:maxCount 1 ;
  sh:name "Sts_Overload" ;
  sh:order "25"^^xsd:decimal ;
.
pgont:FVNR_Sts_Running-output
  a sh:PropertyShape ;
  sh:path edg:output ;
  rdfs:isDefinedBy  ;
  sh:class pgont:RunningStatus ;
  sh:description "FF: Running Status" ;
  sh:group edg:TraceableGroup ;
  sh:maxCount 1 ;
  sh:name "Sts_Running" ;
  sh:order "25"^^xsd:decimal ;




The first property shape says that an instance of pgont:FVNR can have 
at most one value for edg:output and the value must be a member of 
pgont:FaultCondition class.


The second property shape says that an instance of pgont:FVNR can have 
at most one value for edg:output and the value must be a member of 
pgont:RunningStatus class.


The only way this could be true is if:either pgont:RunningStatus is a 
subclass of pgont:FaultCondition or pgont:FaultCondition is a subclass 
of pgont:RunningStatus AND, of course, these shapes say that you would 
not have more than one triple with a given subject and edg:output as a 
predicate.


Qualified value shapes will solve this problem, but on the form it is 
the same path and there is no way to separate these triples. 
Ultimately, you would have in the data:


:R1 edg:output :R2, :R3 and so on.

And the UI will display them together. The edit form is not going to 
be able to figure out that {:R1 edg:output :R2} corresponds to the 
property shape 1 while {:R1 edg:output :R3} corresponds to the 
property shape 2 and therefore it should, somehow, display them 
separately and let you enter and modify them separately.


This addressed the common OWL use case where the same property 
pointed to instances of different classes


Yes, you can do this with SHACL by either having all these classes be 
a subclass of a common parent or by using qualified value shapes.


and it was pertinent to the user to show them the class of the 
instance to tell them what they were seeing.


This does not change the nature of the property in the data, so the 
field name itself is the same. The values would have different types.


If this is for display only (basically a report) and not for editing, 
you could generate a view that would display whatever you want e.g., 
display the class they belong to in parenthesis after each resource.


You could, for example, create another property e.g., :typedOutput and 
back it by sh:values rule that would generate its values by taking 
labels of the resources that are values of edg:output and appending 
the class label to them.



On Jul 7, 2020, at 9:14 PM, Tim Smith > wrote:


Hi Holger,

Thank you for the tip on QualifiedValueShapeConstraintComponent.  I'm 
not deep enough into SHACL to reliably make the best choice. Time is 
the best teacher!


Regarding sh:name...  I was specifically trying to avoid "property 
proliferation" as I already have "class proliferation" when capturing 
the different types of outputs for the 128 device types in my model.  
One of my perceived benefits of SHACL was to be able to 
reuse properties but give each use a different semantic meaning by 
naming the property shape accordingly.  This addressed the common OWL 
use case where the same property pointed to instances of different 
classes and it was pertinent to the user to show t

Re: [topbraid-users] Q: EDG - How does display property shapes?

2020-07-07 Thread Irene Polikoff
Hi Tim,

It would be highly irregular to create, for the same class/node shape, multiple 
property shapes with the same path and give them different sh:name. It would be 
misleading as, in the data, these will be the same properties.

Further, what you are defining below is contradictory

>>> pgont:FVNR
>>>   a edg:CustomAssetClass ;
>>>   a sh:NodeShape ;
>>>   edg:acronym "FVNR" ;
>>>   edg:description "To Be Determined" ;
>>>   rdfs:isDefinedBy >> > ;
>>>   rdfs:label "FVNR" ;
>>>   rdfs:subClassOf pgont:ElectricMotorStarter ;
>>>   sh:property pgont:FVNR_Sts_Overload-output ;
>>>   sh:property pgont:FVNR_Sts_Running-output ;
>>> .
>>> pgont:FVNR_Sts_Overload-output
>>>   a sh:PropertyShape ;
>>>   sh:path edg:output ;
>>>   rdfs:isDefinedBy >> > ;
>>>   sh:class pgont:FaultCondition ;
>>>   sh:description "FF: Control Overload" ;
>>>   sh:group edg:TraceableGroup ;
>>>   sh:maxCount 1 ;
>>>   sh:name "Sts_Overload" ;
>>>   sh:order "25"^^xsd:decimal ;
>>> .
>>> pgont:FVNR_Sts_Running-output
>>>   a sh:PropertyShape ;
>>>   sh:path edg:output ;
>>>   rdfs:isDefinedBy >> > ;
>>>   sh:class pgont:RunningStatus ;
>>>   sh:description "FF: Running Status" ;
>>>   sh:group edg:TraceableGroup ;
>>>   sh:maxCount 1 ;
>>>   sh:name "Sts_Running" ;
>>>   sh:order "25"^^xsd:decimal ;

The first property shape says that an instance of pgont:FVNR can have at most 
one value for edg:output and the value must be a member of pgont:FaultCondition 
class. 

The second property shape says that an instance of pgont:FVNR can have at most 
one value for edg:output and the value must be a member of pgont:RunningStatus 
class.  

The only way this could be true is if:either pgont:RunningStatus is a subclass 
of pgont:FaultCondition or pgont:FaultCondition is a subclass of 
pgont:RunningStatus AND, of course, these shapes say that you would not have 
more than one triple with a given subject and edg:output as a predicate.

Qualified value shapes will solve this problem, but on the form it is the same 
path and there is no way to separate these triples. Ultimately, you would have 
in the data:

:R1 edg:output :R2, :R3 and so on. 

And the UI will display them together. The edit form is not going to be able to 
figure out that {:R1 edg:output :R2} corresponds to the property shape 1 while 
{:R1 edg:output :R3} corresponds to the property shape 2 and therefore it 
should, somehow, display them separately and let you enter and modify them 
separately. 

> This addressed the common OWL use case where the same property pointed to 
> instances of different classes

Yes, you can do this with SHACL by either having all these classes be a 
subclass of a common parent or by using qualified value shapes.

> and it was pertinent to the user to show them the class of the instance to 
> tell them what they were seeing.

This does not change the nature of the property in the data, so the field name 
itself is the same. The values would have different types. 

If this is for display only (basically a report) and not for editing, you could 
generate a view that would display whatever you want e.g., display the class 
they belong to in parenthesis after each resource.

You could, for example, create another property e.g., :typedOutput and back it 
by sh:values rule that would generate its values by taking labels of the 
resources that are values of edg:output and appending the class label to them.


> On Jul 7, 2020, at 9:14 PM, Tim Smith  wrote:
> 
> Hi Holger,
> 
> Thank you for the tip on QualifiedValueShapeConstraintComponent.  I'm not 
> deep enough into SHACL to reliably make the best choice.  Time is the best 
> teacher!
> 
> Regarding sh:name...  I was specifically trying to avoid "property 
> proliferation" as I already have "class proliferation" when capturing the 
> different types of outputs for the 128 device types in my model.  One of my 
> perceived benefits of SHACL was to be able to reuse properties but give each 
> use a different semantic meaning by naming the property shape accordingly.  
> This addressed the common OWL use case where the same property pointed to 
> instances of different classes and it was pertinent to the user to show them 
> the class of the instance to tell them what they were seeing.
> 
> Prior to today, I thought the forms just pulled the name from sh:name but I 
> see now that it does something like pulling the first sh:name it encounters 
> for a specific sh:path and re-uses it.  I noticed this artifact when looking 
> at more complicated device types that have numerous outputs like a Flow 
> Controller.  FVNR is a simple case.  Is there a reason that the form doesn't 
> just display the sh:name to the user, regardless of the property?  I'm trying 
> to determ

Re: [topbraid-users] Q: EDG - How does display property shapes?

2020-07-07 Thread Tim Smith
Hi Holger,

Thank you for the tip on QualifiedValueShapeConstraintComponent.  I'm not
deep enough into SHACL to reliably make the best choice.  Time is the best
teacher!

Regarding sh:name...  I was specifically trying to avoid "property
proliferation" as I already have "class proliferation" when capturing the
different types of outputs for the 128 device types in my model.  One of my
perceived benefits of SHACL was to be able to reuse properties but give
each use a different semantic meaning by naming the property shape
accordingly.  This addressed the common OWL use case where the same
property pointed to instances of different classes and it was pertinent to
the user to show them the class of the instance to tell them what they were
seeing.

Prior to today, I thought the forms just pulled the name from sh:name but I
see now that it does something like pulling the first sh:name it encounters
for a specific sh:path and re-uses it.  I noticed this artifact when
looking at more complicated device types that have numerous outputs like a
Flow Controller.  FVNR is a simple case.  Is there a reason that the form
doesn't just display the sh:name to the user, regardless of the property?
I'm trying to determine if the user interface is about to drive the
modeling or if there is some underlying aspect of SHACL that I'm missing.
If it's the former, is there a possibility to re-visit the implementation?
I have 128 classes that have this problem.  (note that it won't take 128
properties to fix it but it is a common modeling pattern in my domains)

Thanks,

Tim


On Tue, Jul 7, 2020 at 8:43 PM Holger Knublauch 
wrote:

> Hi Tim,
>
> if you want to use the same property I think you're rather looking at
>
> https://www.w3.org/TR/shacl/#QualifiedValueShapeConstraintComponent
>
> to say that "one of them needs to be running indicator" and "one of them
> needs to be fault indicator".
>
> But while that would work on a constraint checking level, it will not make
> sense w.r.t. sh:name and the form editor. The label should be the same in
> both cases, which I believe indicates that you're better off introducing
> separate properties.
>
> Holger
>
>
> On 8/07/2020 10:02, Tim Smith wrote:
>
> Hi Holger,
>
> In this case, that is correct.  The FVNR class represents a physical
> device, a type of electric motor starter.  These devices have two outputs,
> a running indicator and a fault indicator.  These outputs are typically
> wired into a Programmable Logic Controller (PLC).  Thus, I've chosen to
> model the outputs as specific types of data elements.  This model is
> intended to be able capture and show lineage for all of the data elements
> produced by devices on a manufacturing line.  This data typically flows
> into a PLC and out into various OT/IT systems.  It will also enable me to
> capture the control loops on the line.
>
> I own the model and am open to better ways of doing it.
>
> Tim
>
> On Tue, Jul 7, 2020 at 7:13 PM Holger Knublauch 
> wrote:
>
>> Hi Tim,
>> are you sure both property shapes are about the same property edg:output?
>> This doesn't look right because they carry different sh:class constraints
>> in both cases.
>>
>> Regards,
>> Holger
>>
>>
>> On 8/07/2020 04:52, Tim Smith wrote:
>>
>> Hi,
>>
>> I am auto-generating classes and property shapes from spreadsheets.  I
>> have an issue where EDG is not displaying the name of the property shape
>> correctly in the declared properties section of a class form.  In the
>> example below, note that Sts_Overload is displayed as the property name in
>> both cases but sh:name contains Sts_Running for the upper entry.  Source
>> code for the class/node shape and property shapes is pasted at the bottom.
>> This is happening for all of my generated classes but does not happen for
>> classes and property shapes I manually create in EDG.
>>
>> Note that when I say generated, I use an insert query in TBC to construct
>> the triples from a spreadsheet and insert them into an empty graph.  The
>> graph containing the triples is then imported into an empty ontology in EDG.
>>
>> I'm baffled as to what is different and I'm hoping another set of eyes
>> will see the problem.  Thanks in advance for your help,
>>
>> Tim
>> [image: image.png]
>> pgont:FVNR
>>   a edg:CustomAssetClass ;
>>   a sh:NodeShape ;
>>   edg:acronym "FVNR" ;
>>   edg:description "To Be Determined" ;
>>   rdfs:isDefinedBy  ;
>>   rdfs:label "FVNR" ;
>>   rdfs:subClassOf pgont:ElectricMotorStarter ;
>>   sh:property pgont:FVNR_Sts_Overload-output ;
>>   sh:property pgont:FVNR_Sts_Running-output ;
>> .
>> pgont:FVNR_Sts_Overload-output
>>   a sh:PropertyShape ;
>>   sh:path edg:output ;
>>   rdfs:isDefinedBy  ;
>>   sh:class pgont:FaultCondition ;
>>   sh:description "FF: Control Overload" ;
>>   sh:group edg:TraceableGroup ;
>>   sh:maxCount 1 ;
>>   sh:name "Sts_Overload" ;
>>   sh:order "25"^^xsd:decimal ;
>> .
>> pgont:FVNR_

Re: [topbraid-users] Q: EDG - How does display property shapes?

2020-07-07 Thread Holger Knublauch

Hi Tim,

if you want to use the same property I think you're rather looking at

https://www.w3.org/TR/shacl/#QualifiedValueShapeConstraintComponent

to say that "one of them needs to be running indicator" and "one of them 
needs to be fault indicator".


But while that would work on a constraint checking level, it will not 
make sense w.r.t. sh:name and the form editor. The label should be the 
same in both cases, which I believe indicates that you're better off 
introducing separate properties.


Holger


On 8/07/2020 10:02, Tim Smith wrote:

Hi Holger,

In this case, that is correct.  The FVNR class represents a physical 
device, a type of electric motor starter.  These devices have two 
outputs, a running indicator and a fault indicator.  These outputs are 
typically wired into a Programmable Logic Controller (PLC).  Thus, 
I've chosen to model the outputs as specific types of data elements.  
This model is intended to be able capture and show lineage for all of 
the data elements produced by devices on a manufacturing line.  This 
data typically flows into a PLC and out into various OT/IT systems.  
It will also enable me to capture the control loops on the line.


I own the model and am open to better ways of doing it.

Tim

On Tue, Jul 7, 2020 at 7:13 PM Holger Knublauch 
mailto:hol...@topquadrant.com>> wrote:


Hi Tim,

are you sure both property shapes are about the same property
edg:output? This doesn't look right because they carry different
sh:class constraints in both cases.

Regards,
Holger


On 8/07/2020 04:52, Tim Smith wrote:

Hi,

I am auto-generating classes and property shapes from
spreadsheets.  I have an issue where EDG is not displaying the
name of the property shape correctly in the declared properties
section of a class form.  In the example below, note that
Sts_Overload is displayed as the property name in both cases but
sh:name contains Sts_Running for the upper entry.  Source code
for the class/node shape and property shapes is pasted at the
bottom.  This is happening for all of my generated classes but
does not happen for classes and property shapes I manually create
in EDG.

Note that when I say generated, I use an insert query in TBC to
construct the triples from a spreadsheet and insert them into an
empty graph.  The graph containing the triples is then imported
into an empty ontology in EDG.

I'm baffled as to what is different and I'm hoping another set of
eyes will see the problem.  Thanks in advance for your help,

Tim
image.png
pgont:FVNR
  a edg:CustomAssetClass ;
  a sh:NodeShape ;
  edg:acronym "FVNR" ;
  edg:description "To Be Determined" ;
  rdfs:isDefinedBy  ;
  rdfs:label "FVNR" ;
  rdfs:subClassOf pgont:ElectricMotorStarter ;
  sh:property pgont:FVNR_Sts_Overload-output ;
  sh:property pgont:FVNR_Sts_Running-output ;
.
pgont:FVNR_Sts_Overload-output
  a sh:PropertyShape ;
  sh:path edg:output ;
  rdfs:isDefinedBy  ;
  sh:class pgont:FaultCondition ;
  sh:description "FF: Control Overload" ;
  sh:group edg:TraceableGroup ;
  sh:maxCount 1 ;
  sh:name "Sts_Overload" ;
  sh:order "25"^^xsd:decimal ;
.
pgont:FVNR_Sts_Running-output
  a sh:PropertyShape ;
  sh:path edg:output ;
  rdfs:isDefinedBy  ;
  sh:class pgont:RunningStatus ;
  sh:description "FF: Running Status" ;
  sh:group edg:TraceableGroup ;
  sh:maxCount 1 ;
  sh:name "Sts_Running" ;
  sh:order "25"^^xsd:decimal ;
.
-- 
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-users+unsubscr...@googlegroups.com
.
To view this discussion on the web visit

https://groups.google.com/d/msgid/topbraid-users/CAF0WbnLc5O0h1Q29OB5ZAqPfmYkT0KbrfVkyJmy7z8-iZdqBsA%40mail.gmail.com

.
-- 
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-users+unsubscr...@googlegroups.com
.
To view this discussion on the web visit

https://groups.google.com/d/msgid/topbraid-users/f9493d61-59fe-b295-373c-899efeffb5e6%40topquadrant.com

.

--
Yo

Re: [topbraid-users] Q: EDG - How does display property shapes?

2020-07-07 Thread Tim Smith
Hi Holger,

In this case, that is correct.  The FVNR class represents a physical
device, a type of electric motor starter.  These devices have two outputs,
a running indicator and a fault indicator.  These outputs are typically
wired into a Programmable Logic Controller (PLC).  Thus, I've chosen to
model the outputs as specific types of data elements.  This model is
intended to be able capture and show lineage for all of the data elements
produced by devices on a manufacturing line.  This data typically flows
into a PLC and out into various OT/IT systems.  It will also enable me to
capture the control loops on the line.

I own the model and am open to better ways of doing it.

Tim

On Tue, Jul 7, 2020 at 7:13 PM Holger Knublauch 
wrote:

> Hi Tim,
> are you sure both property shapes are about the same property edg:output?
> This doesn't look right because they carry different sh:class constraints
> in both cases.
>
> Regards,
> Holger
>
>
> On 8/07/2020 04:52, Tim Smith wrote:
>
> Hi,
>
> I am auto-generating classes and property shapes from spreadsheets.  I
> have an issue where EDG is not displaying the name of the property shape
> correctly in the declared properties section of a class form.  In the
> example below, note that Sts_Overload is displayed as the property name in
> both cases but sh:name contains Sts_Running for the upper entry.  Source
> code for the class/node shape and property shapes is pasted at the bottom.
> This is happening for all of my generated classes but does not happen for
> classes and property shapes I manually create in EDG.
>
> Note that when I say generated, I use an insert query in TBC to construct
> the triples from a spreadsheet and insert them into an empty graph.  The
> graph containing the triples is then imported into an empty ontology in EDG.
>
> I'm baffled as to what is different and I'm hoping another set of eyes
> will see the problem.  Thanks in advance for your help,
>
> Tim
> [image: image.png]
> pgont:FVNR
>   a edg:CustomAssetClass ;
>   a sh:NodeShape ;
>   edg:acronym "FVNR" ;
>   edg:description "To Be Determined" ;
>   rdfs:isDefinedBy  ;
>   rdfs:label "FVNR" ;
>   rdfs:subClassOf pgont:ElectricMotorStarter ;
>   sh:property pgont:FVNR_Sts_Overload-output ;
>   sh:property pgont:FVNR_Sts_Running-output ;
> .
> pgont:FVNR_Sts_Overload-output
>   a sh:PropertyShape ;
>   sh:path edg:output ;
>   rdfs:isDefinedBy  ;
>   sh:class pgont:FaultCondition ;
>   sh:description "FF: Control Overload" ;
>   sh:group edg:TraceableGroup ;
>   sh:maxCount 1 ;
>   sh:name "Sts_Overload" ;
>   sh:order "25"^^xsd:decimal ;
> .
> pgont:FVNR_Sts_Running-output
>   a sh:PropertyShape ;
>   sh:path edg:output ;
>   rdfs:isDefinedBy  ;
>   sh:class pgont:RunningStatus ;
>   sh:description "FF: Running Status" ;
>   sh:group edg:TraceableGroup ;
>   sh:maxCount 1 ;
>   sh:name "Sts_Running" ;
>   sh:order "25"^^xsd:decimal ;
> .
> --
> 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-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/topbraid-users/CAF0WbnLc5O0h1Q29OB5ZAqPfmYkT0KbrfVkyJmy7z8-iZdqBsA%40mail.gmail.com
> 
> .
>
> --
> 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-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/topbraid-users/f9493d61-59fe-b295-373c-899efeffb5e6%40topquadrant.com
> 
> .
>

-- 
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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/CAF0Wbn%2BYFYEp-1aMyt6tKB_ajJHBCbjNA2MRZ-xsdXV_FwcRsw%40mail.gmail.com.


Re: [topbraid-users] [SHACL API] difference between jena.apache.org/documentation/shacl and github.com/TopQuadrant/shacl?

2020-07-07 Thread Holger Knublauch
The one built into Jena has the advantage of being built into Jena out 
of the box and I believe available through Fuseki. I haven't tracked 
whether it is already used elsewhere and you may want to follow up on 
the jena mailing list.


The TQ SHACL API has broader coverage of SHACL Advanced Features and 
SHACL-JS and is the one that is integrated into TopBraid products, i.e. 
it has a full editor and interactive constraint checking tooling around it.


HTH
Holger


On 8/07/2020 00:04, Emmanuel Oga wrote:

Hello,

I'm starting to look into validating some triples with SHACL. I'm 
using Jena as triplestore.


There's some SHACL documention on 
https://jena.apache.org/documentation/shacl/,
but there's also the Jena based 
https://github.com/TopQuadrant/shacl package.


I was wondering what's the difference between Jena's and TopQuadrant 
implementation,

if there are any guidelines on when to favor one over the other, etc.

Thank you!
--
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-users+unsubscr...@googlegroups.com 
.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/0342c79c-8164-46b0-8469-3f1be20f0c36o%40googlegroups.com 
.


--
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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/d6ba5c6d-755c-fc64-3cb3-255219504d74%40topquadrant.com.


Re: [topbraid-users] Q: EDG - How does display property shapes?

2020-07-07 Thread Holger Knublauch

Hi Tim,

are you sure both property shapes are about the same property 
edg:output? This doesn't look right because they carry different 
sh:class constraints in both cases.


Regards,
Holger


On 8/07/2020 04:52, Tim Smith wrote:

Hi,

I am auto-generating classes and property shapes from spreadsheets.  I 
have an issue where EDG is not displaying the name of the property 
shape correctly in the declared properties section of a class form.  
In the example below, note that Sts_Overload is displayed as the 
property name in both cases but sh:name contains Sts_Running for the 
upper entry.  Source code for the class/node shape and property shapes 
is pasted at the bottom.  This is happening for all of my generated 
classes but does not happen for classes and property shapes I manually 
create in EDG.


Note that when I say generated, I use an insert query in TBC to 
construct the triples from a spreadsheet and insert them into an empty 
graph.  The graph containing the triples is then imported into an 
empty ontology in EDG.


I'm baffled as to what is different and I'm hoping another set of eyes 
will see the problem.  Thanks in advance for your help,


Tim
image.png
pgont:FVNR
  a edg:CustomAssetClass ;
  a sh:NodeShape ;
  edg:acronym "FVNR" ;
  edg:description "To Be Determined" ;
  rdfs:isDefinedBy  ;
  rdfs:label "FVNR" ;
  rdfs:subClassOf pgont:ElectricMotorStarter ;
  sh:property pgont:FVNR_Sts_Overload-output ;
  sh:property pgont:FVNR_Sts_Running-output ;
.
pgont:FVNR_Sts_Overload-output
  a sh:PropertyShape ;
  sh:path edg:output ;
  rdfs:isDefinedBy  ;
  sh:class pgont:FaultCondition ;
  sh:description "FF: Control Overload" ;
  sh:group edg:TraceableGroup ;
  sh:maxCount 1 ;
  sh:name "Sts_Overload" ;
  sh:order "25"^^xsd:decimal ;
.
pgont:FVNR_Sts_Running-output
  a sh:PropertyShape ;
  sh:path edg:output ;
  rdfs:isDefinedBy  ;
  sh:class pgont:RunningStatus ;
  sh:description "FF: Running Status" ;
  sh:group edg:TraceableGroup ;
  sh:maxCount 1 ;
  sh:name "Sts_Running" ;
  sh:order "25"^^xsd:decimal ;
.
--
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-users+unsubscr...@googlegroups.com 
.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/CAF0WbnLc5O0h1Q29OB5ZAqPfmYkT0KbrfVkyJmy7z8-iZdqBsA%40mail.gmail.com 
.


--
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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/f9493d61-59fe-b295-373c-899efeffb5e6%40topquadrant.com.


[topbraid-users] Q: EDG - How does display property shapes?

2020-07-07 Thread Tim Smith
Hi,

I am auto-generating classes and property shapes from spreadsheets.  I have
an issue where EDG is not displaying the name of the property shape
correctly in the declared properties section of a class form.  In the
example below, note that Sts_Overload is displayed as the property name in
both cases but sh:name contains Sts_Running for the upper entry.  Source
code for the class/node shape and property shapes is pasted at the bottom.
This is happening for all of my generated classes but does not happen for
classes and property shapes I manually create in EDG.

Note that when I say generated, I use an insert query in TBC to construct
the triples from a spreadsheet and insert them into an empty graph.  The
graph containing the triples is then imported into an empty ontology in EDG.

I'm baffled as to what is different and I'm hoping another set of eyes will
see the problem.  Thanks in advance for your help,

Tim
[image: image.png]
pgont:FVNR
  a edg:CustomAssetClass ;
  a sh:NodeShape ;
  edg:acronym "FVNR" ;
  edg:description "To Be Determined" ;
  rdfs:isDefinedBy  ;
  rdfs:label "FVNR" ;
  rdfs:subClassOf pgont:ElectricMotorStarter ;
  sh:property pgont:FVNR_Sts_Overload-output ;
  sh:property pgont:FVNR_Sts_Running-output ;
.
pgont:FVNR_Sts_Overload-output
  a sh:PropertyShape ;
  sh:path edg:output ;
  rdfs:isDefinedBy  ;
  sh:class pgont:FaultCondition ;
  sh:description "FF: Control Overload" ;
  sh:group edg:TraceableGroup ;
  sh:maxCount 1 ;
  sh:name "Sts_Overload" ;
  sh:order "25"^^xsd:decimal ;
.
pgont:FVNR_Sts_Running-output
  a sh:PropertyShape ;
  sh:path edg:output ;
  rdfs:isDefinedBy  ;
  sh:class pgont:RunningStatus ;
  sh:description "FF: Running Status" ;
  sh:group edg:TraceableGroup ;
  sh:maxCount 1 ;
  sh:name "Sts_Running" ;
  sh:order "25"^^xsd:decimal ;
.

-- 
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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/CAF0WbnLc5O0h1Q29OB5ZAqPfmYkT0KbrfVkyJmy7z8-iZdqBsA%40mail.gmail.com.


Re: [topbraid-users] equiv. in shacl

2020-07-07 Thread Irene Polikoff
I would use Triple Rule as in the example. I typically do not recommend 
sh:values for df:type because this makes it calculated only, no way to enter a 
value.

> On Jul 7, 2020, at 11:08 AM, 'Bohms, H.M. (Michel)' via TopBraid Suite Users 
>  wrote:
> 
> Thx, for the way back I guess using sh:values? (at someotherclass)
>  
>  
>  
>  
>  
> Dr. ir. H.M. (Michel) Böhms
> Senior Data Scientist
> 
> T +31888663107
> M +31630381220
> E michel.bo...@tno.nl 
> Location 
> 
> 
>  
>  
> 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.
>  
>  
>  
>  
> Van: topbraid-users@googlegroups.com  
> mailto:topbraid-users@googlegroups.com>> 
> Namens Irene Polikoff
> Verzonden: Tuesday, July 7, 2020 4:59 PM
> Aan: topbraid-users@googlegroups.com 
> Onderwerp: Re: [topbraid-users] equiv. in shacl
>  
> For inferencing, I would associate a rule with :SomeOtherClass to infer 
> membership in :ExampleClass (made up name since you did not give one) if the 
> hasValue condition is met.
>  
> It is similar to the below example where type Square is inferred for a 
> rectangle with the same width and height.
>  
> ex:Rectangle a rdfs:Class, sh:NodeShape ;
> rdfs:label "Rectangle" ; 
> sh:property  [ sh:path ex:height ;
>   sh:datatype xsd:integer ; 
>   sh:maxCount 1 ; 
>   sh:minCount 1 ; 
>   sh:name "height" ; ] ; 
> sh:property [ sh:path ex:width ;
>   sh:datatype xsd:integer ; 
>   sh:maxCount 1 ; 
>   sh:minCount 1 ; 
>   sh:name "width" ; ] ; 
> sh:rule [ a sh:TripleRule ;
>   sh:subject sh:this ;
> sh:predicate rdf:type ;
>   sh:object ex:Square ;
>   sh:condition [ sh:property [ sh:path ex:width ; sh:equals ex:height ; ] ; ] 
> ; ] .
> 
> 
> Of course, you would use sh:hasValue instead of sh:equals.
>  
> For constraint checking, you need to have the following for :ExampleClass
>  
> hasValue :v1 constraint for :p1 path and 
> hasValue  :SomeOtherClass constraint for rdf:type/rdfs:subClassOf* path.
> 
> 
> On Jul 7, 2020, at 10:41 AM, 'Bohms, H.M. (Michel)' via TopBraid Suite Users 
> mailto:topbraid-users@googlegroups.com>> 
> wrote:
>  
> Having an owl-rl restriction like:
>  
>   owl:equivalentClass [
>   rdf:type owl:Class ;
>   owl:intersectionOf (
>   :SomeOtherClass
>   [
> rdf:type owl:Restriction ;
> owl:hasValue :v1 ;
> owl:onProperty :p1 ;
>   ]
>  
> How would that best translate to SHACL? (under an inference assumption, not 
> just checking).
>  
> Should I use SHACL-AF sparql construct for each direction?
> Or can I reuse some AF syntactic sugar construct in one or both directions?
>  
> Thx Michel
>  
>  
>  
> Dr. ir. H.M. (Michel) Böhms
> Senior Data Scientist
> 
> 
> T +31888663107
> M +31630381220
> E michel.bo...@tno.nl 
> Location 
> 
> 
>  
>  
> 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-users+unsubscr...@googlegroups.com 
> .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/topbraid-users/74333520d9ad48e6a4f5e7ebb8c596a0%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-users+unsubscr...@googlegroups.com 
> 

RE: [topbraid-users] equiv. in shacl

2020-07-07 Thread 'Bohms, H.M. (Michel)' via TopBraid Suite Users
Thx, for the way back I guess using sh:values? (at someotherclass)






Dr. ir. H.M. (Michel) Böhms
Senior Data Scientist


T +31888663107
M +31630381220
E michel.bo...@tno.nl

Location



[cid:image001.gif@01D65481.2C308520]

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.









Van: topbraid-users@googlegroups.com  Namens 
Irene Polikoff
Verzonden: Tuesday, July 7, 2020 4:59 PM
Aan: topbraid-users@googlegroups.com
Onderwerp: Re: [topbraid-users] equiv. in shacl

For inferencing, I would associate a rule with :SomeOtherClass to infer 
membership in :ExampleClass (made up name since you did not give one) if the 
hasValue condition is met.

It is similar to the below example where type Square is inferred for a 
rectangle with the same width and height.

ex:Rectangle a rdfs:Class, sh:NodeShape ;
rdfs:label "Rectangle" ;
sh:property  [ sh:path ex:height ;
  sh:datatype xsd:integer ;
  sh:maxCount 1 ;
  sh:minCount 1 ;
  sh:name "height" ; ] ;
sh:property [ sh:path ex:width ;
  sh:datatype xsd:integer ;
  sh:maxCount 1 ;
  sh:minCount 1 ;
  sh:name "width" ; ] ;
sh:rule [ a sh:TripleRule ;
  sh:subject sh:this ;
sh:predicate rdf:type ;
  sh:object ex:Square ;
  sh:condition [ sh:property [ sh:path ex:width ; sh:equals ex:height ; ] ; ] ; 
] .


Of course, you would use sh:hasValue instead of sh:equals.

For constraint checking, you need to have the following for :ExampleClass

hasValue :v1 constraint for :p1 path and
hasValue  :SomeOtherClass constraint for rdf:type/rdfs:subClassOf* path.


On Jul 7, 2020, at 10:41 AM, 'Bohms, H.M. (Michel)' via TopBraid Suite Users 
mailto:topbraid-users@googlegroups.com>> wrote:

Having an owl-rl restriction like:

  owl:equivalentClass [
  rdf:type owl:Class ;
  owl:intersectionOf (
  :SomeOtherClass
  [
rdf:type owl:Restriction ;
owl:hasValue :v1 ;
owl:onProperty :p1 ;
  ]

How would that best translate to SHACL? (under an inference assumption, not 
just checking).

Should I use SHACL-AF sparql construct for each direction?
Or can I reuse some AF syntactic sugar construct in one or both directions?

Thx Michel




Dr. ir. H.M. (Michel) Böhms
Senior Data Scientist



T +31888663107
M +31630381220
E michel.bo...@tno.nl

Location





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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/74333520d9ad48e6a4f5e7ebb8c596a0%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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/4B10241B-3800-4C53-A655-202F0CC83C3E%40topquadrant.com.

-- 
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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/2170b0

Re: [topbraid-users] equiv. in shacl

2020-07-07 Thread Irene Polikoff
For inferencing, I would associate a rule with :SomeOtherClass to infer 
membership in :ExampleClass (made up name since you did not give one) if the 
hasValue condition is met.

It is similar to the below example where type Square is inferred for a 
rectangle with the same width and height.

ex:Rectangle a rdfs:Class, sh:NodeShape ;
rdfs:label "Rectangle" ;
sh:property  [ sh:path ex:height ;
  sh:datatype xsd:integer ;
  sh:maxCount 1 ;
  sh:minCount 1 ;
  sh:name "height" ; ] ;
sh:property [ sh:path ex:width ;
  sh:datatype xsd:integer ;
  sh:maxCount 1 ;
  sh:minCount 1 ;
  sh:name "width" ; ] ;
sh:rule [ a sh:TripleRule ;
  sh:subject sh:this ;
sh:predicate rdf:type ;
  sh:object ex:Square ;
  sh:condition [ sh:property [ sh:path ex:width ; sh:equals ex:height ; ] ; ] ; 
] .

Of course, you would use sh:hasValue instead of sh:equals.

For constraint checking, you need to have the following for :ExampleClass

hasValue :v1 constraint for :p1 path and 
hasValue  :SomeOtherClass constraint for rdf:type/rdfs:subClassOf* path.

> On Jul 7, 2020, at 10:41 AM, 'Bohms, H.M. (Michel)' via TopBraid Suite Users 
>  wrote:
> 
> Having an owl-rl restriction like:
>  
>   owl:equivalentClass [
>   rdf:type owl:Class ;
>   owl:intersectionOf (
>   :SomeOtherClass
>   [
> rdf:type owl:Restriction ;
> owl:hasValue :v1 ;
> owl:onProperty :p1 ;
>   ]
>  
> How would that best translate to SHACL? (under an inference assumption, not 
> just checking).
>  
> Should I use SHACL-AF sparql construct for each direction?
> Or can I reuse some AF syntactic sugar construct in one or both directions?
>  
> Thx Michel
>  
>  
>  
> Dr. ir. H.M. (Michel) Böhms
> Senior Data Scientist
> 
> T +31888663107
> M +31630381220
> E michel.bo...@tno.nl 
> Location 
> 
> 
>  
>  
> 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-users+unsubscr...@googlegroups.com 
> .
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/topbraid-users/74333520d9ad48e6a4f5e7ebb8c596a0%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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/4B10241B-3800-4C53-A655-202F0CC83C3E%40topquadrant.com.


[topbraid-users] equiv. in shacl

2020-07-07 Thread 'Bohms, H.M. (Michel)' via TopBraid Suite Users
Having an owl-rl restriction like:

  owl:equivalentClass [
  rdf:type owl:Class ;
  owl:intersectionOf (
  :SomeOtherClass
  [
rdf:type owl:Restriction ;
owl:hasValue :v1 ;
owl:onProperty :p1 ;
  ]

How would that best translate to SHACL? (under an inference assumption, not 
just checking).

Should I use SHACL-AF sparql construct for each direction?
Or can I reuse some AF syntactic sugar construct in one or both directions?

Thx Michel




Dr. ir. H.M. (Michel) Böhms
Senior Data Scientist


T +31888663107
M +31630381220
E michel.bo...@tno.nl

Location



[cid:image001.gif@01D6547D.7A8E4E40]

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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/74333520d9ad48e6a4f5e7ebb8c596a0%40tno.nl.


[topbraid-users] [SHACL API] difference between jena.apache.org/documentation/shacl and github.com/TopQuadrant/shacl?

2020-07-07 Thread Emmanuel Oga
Hello,

I'm starting to look into validating some triples with SHACL. I'm using 
Jena as triplestore.

There's some SHACL documention on 
https://jena.apache.org/documentation/shacl/,
but there's also the Jena based https://github.com/TopQuadrant/shacl
 package.

I was wondering what's the difference between Jena's and TopQuadrant 
implementation,
if there are any guidelines on when to favor one over the other, etc.

Thank you!

-- 
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-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/0342c79c-8164-46b0-8469-3f1be20f0c36o%40googlegroups.com.