< First, you need to realize that the kind of constraint check you are looking for is not covered in standard SWP-based reasoners because they assume an open world. I.e. you cannot use cardinality to check consistency because there isn't a way to know if all known properties are being included.>
Scott meant in the standard OWL-based reasoners. Open world assumption used in RDFS and OWL means that being below of min cardinality or below exact cardinality will never raise a violation because it is assumed that we don’t have all the data. Further, being above max cardinality or above exact cardinality will not necessarily raise a violation either because different values may represent the same resource. One can use SPIN to operate under a more common (and typically more useful) closed world assumption for data constrains checking. Regards, Irene From: [email protected] [mailto:[email protected]] On Behalf Of Scott Henninger Sent: Monday, January 12, 2015 4:46 PM To: [email protected] Subject: Re: [topbraid-users] TBC Quick Start guide - can't identify problems after bornIn cardinalty constraint is set Nate; The tutorial is designed to show some basic modeling features in TopBraid Composer. To run rules or constraints requires some additional steps. (See the How to use SPIN section on http://www.topquadrant.com/technology/sparql-rules-spin/ for more.) First, you need to realize that the kind of constraint check you are looking for is not covered in standard SWP-based reasoners because they assume an open world. I.e. you cannot use cardinality to check consistency because there isn't a way to know if all known properties are being included. Fortunately, you can use come closed-world constraints, and this is what SPIN excels at. There are a couple of approaches. The first is to use a someValuesOf restriction wit a CWA reasoning profile. To do this: 1. modify the restriction from the tutorial to be a someValuesFrom restriction. You can use the same wizard and can define this in a subClassOf property for :Person. The Manchester syntax will look like: person:bornIn some countries:Country 2. In the Ontology Home, open the Profile sub-tab (see Help > TopBraid Composer > User Interface Overview > Resource Editor> Ontology Profile) 3. Choose "SPIN constraints on OWL axioms with CWA) 4. Refresh the Problems view. This should get you the constraint violations you are looking for. Note that a someValuesOf restriction was used because the CWA reasoning profile used does not have any CWA rules for cardinality. This can be added as a SPIN constraint using the following procedure: 5. Import spin.ttl from /TopBraid/SPIN/spin.ttl 6. in the person:Person class define the following in the spin:constraint property # Each person must have at one instance of person:bornIn ASK WHERE { NOT EXISTS { ?this person:bornIn ?country . } . } If you subsequently refresh the problems view, the comment at the beginning of the constraint will appear for each member of person:Person that does not have an instance of person:bornIn. One could use the same constraint technique to create a constraint violation rule, that looks for the cardinality restriction from the quickstart guide, to query the restrictions on a class and raise a violation when the cardinality restriction is violated. This could in fact be added to the CWA profile included in Composer, but I leave that to another exercise... Let us know if this is helpful. -- Scott On 1/11/2015 10:37 AM, Nate Marks wrote: HI everyone! I'm sure I'm missing something silly, but I just followed the quickstart guide ( http://www.topquadrant.com/docs/TBC-Getting-Started-Guide40.pdf ) and the last step is to set a cardinality constraint for bornIn. Though it's not covered in the guide, I expected to see a failure in Problems when I did that, but it's not working. Is there some extra step required? Thank you! -- You received this message because you are subscribed to the Google Group "TopBraid Suite Users", the topics of which include Enterprise Vocabulary Network (EVN), Reference Data Manager (RDM), TopBraid Composer, TopBraid Live, TopBraid Insight, SPARQLMotion, SPARQL Web Pages and SPIN. To post to this group, send email to [email protected] --- 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]. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Group "TopBraid Suite Users", the topics of which include Enterprise Vocabulary Network (EVN), Reference Data Manager (RDM), TopBraid Composer, TopBraid Live, TopBraid Insight, SPARQLMotion, SPARQL Web Pages and SPIN. To post to this group, send email to [email protected] --- 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]. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Group "TopBraid Suite Users", the topics of which include Enterprise Vocabulary Network (EVN), Reference Data Manager (RDM), TopBraid Composer, TopBraid Live, TopBraid Insight, SPARQLMotion, SPARQL Web Pages and SPIN. To post to this group, send email to [email protected] --- 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]. For more options, visit https://groups.google.com/d/optout.
