Hi GaBriella,

you can use SHACL Advanced Features to infer values. For your use cases, 
sh:values rules sound like a good match.

See https://datashapes.org/forms.html#inferred-values for the basic mechanism.

In your case, maybe this helps:

ex:MyClass
    a owl:Class, sh:NodeShape ;
    sh:property ex:MyClass-sponsoredInvestment ;
.

ex:MyClass-sponsoredInvestment
    a sh:PropertyShape ;
    sh:path ex:sponsoredInvestment ;
    sh:datatype xsd:boolean ;
    sh:values [
        sh:exists [
            sh:path ex:systemOwner ;
        ] ;
    ]
.

This would mark "sponsoredInvestment" as a read-only property that will be 
automatically computed when displayed and queried, esp on forms, through 
GraphQL and through JavaScript/ADS.

Such sh:values rules can also be expressed in SPARQL or JavaScript/ADS.

Feel free to post your follow-up questions if you need more instructions.

Holger



> On 29 Nov 2022, at 1:02 am, 'GaBriella Branson' via TopBraid Suite Users 
> <[email protected]> wrote:
> 
> Hello,
> 
> I have a series of 10 boolean attributes. I would like "true" to be inferred 
> if another property has a value.
> 
> As an example
> if systemOwner has any value, then sponsoredInvestment is true
> 
> An additional example
> if hostedOn matches NIFC eNet or Denver Federal Center or WRCC, then 
> enterpriseArchitectureSupportedDevelopmentEnvironment is true, but if 
> hostedOn is AWS or Desktop or ESRI Cloud or null, then 
> enterpriseArchitectureSupportedDevelopmentEnvironment is false
> 
> Is this a legitimate use of inferrencing or should I handle this a different 
> way?
> 
> Do you have any recommendations on courses or resources I can use to write 
> these?
> 
> Thanks in advance!
> 
> -- 
> 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 [email protected] 
> <mailto:[email protected]>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/topbraid-users/0cdd2f9d-85dc-43e9-ac81-5f6382513f28n%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/topbraid-users/0cdd2f9d-85dc-43e9-ac81-5f6382513f28n%40googlegroups.com?utm_medium=email&utm_source=footer>.

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/topbraid-users/8A55465A-F45A-44A5-B0F3-C796D108AB92%40topquadrant.com.

Reply via email to