Re: protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

Sabina
Hi Marco,

the topic you raised also was on my mind during the last weeks. As Csongor put it correctly, the fact that the reasoner does not classify your individuals the way you expected is due to the so called Open World Assumption (OWA). However, what I still don't get is: how then, under the OWA do the cardinality restrictions make sense in an ontology? Aren't they basically ignored by the the reasoner in the process of classification? Could somebody share his/her insights?

Thanks a lot!

Sabina




--------------------------------------------
[hidden email] <[hidden email]> schrieb am Do, 13.3.2014:

 Betreff: protege-user Digest, Vol 2, Issue 23
 An: [hidden email]
 Datum: Donnerstag, 13. März, 2014 06:34 Uhr
 
 Send protege-user mailing list
 submissions to
     [hidden email]
 
 To subscribe or unsubscribe via the World Wide Web, visit
     https://mailman.stanford.edu/mailman/listinfo/protege-user
 or, via email, send a message with subject or body 'help'
 to
     [hidden email]
 
 You can reach the person managing the list at
     [hidden email]
 
 When replying, please edit your Subject line so it is more
 specific
 than "Re: Contents of protege-user digest..."
 
 
 Today's Topics:
 
    1. doubts with max (and exactly)
 restriction (Marco Foroni)
    2. Re: doubts with max (and exactly)
 restriction (Csongor Nyulas)
    3. Re: PrF Win - Import w Datamaster?
 (F?zi)
 
 
 ----------------------------------------------------------------------
 
 Message: 1
 Date: Wed, 12 Mar 2014 23:56:53 +0100
 From: Marco Foroni <[hidden email]>
 To: [hidden email]
 Subject: [protege-user] doubts with max (and exactly)
 restriction
 Message-ID:
     <[hidden email]>
 Content-Type: text/plain; charset="iso-8859-1"
 
 Hello, I have some doubts with max (and exactly) restriction
 in owl protege
 and I'm looking for help. I would be very grateful if
 someone could give me
 some advice.
 
 I created a specific example just to try to clarify my
 doubts but without
 success. In my example, I created:
 - two classes: Father and Child
 - the Object Properties HasChild with domain Father and
 range Child
 - 5 individuals: Father1, Father2 (type Father) and Child1,
 Child2, Child3
 (type Son) and the axioms: Father1 != Father2, Child1 !=
 Child2 != Child3
 
 I specified Father1 HasChild Child1 and Father1 HasChild
 Child2, and
 Father2 HasChild Child3 so Father1 and Father2 are father of
 two children
 at most and Father2 is father of one child at most.
 
 I also created two subclasses of Father (defined by
 equivalences with the
 Class Expression Editor):
 - Father_of_one_child_at_most  = Father and (HasChild
 max 1 Child)
 - Father_of_two_children_at_most = Father and (HasChild max
 2 HasChild)
 When I start the reasoner Father1 and Father2 are not
 included in this
 classes (while this problem does not occur with the minimum
 restriction).
 Could someone help me, please?
 -------------- next part --------------
 An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140312/523408d2/attachment-0001.html>
 
 ------------------------------
 
 Message: 2
 Date: Wed, 12 Mar 2014 16:15:11 -0700
 From: Csongor Nyulas <[hidden email]>
 To: [hidden email]
 Subject: Re: [protege-user] doubts with max (and exactly)
 restriction
 Message-ID: <[hidden email]>
 Content-Type: text/plain; charset="iso-8859-1";
 Format="flowed"
 
 Father1 and Father2 may have other children that are not
 stated in this
 ontology. This is why the reasoner can't classify them under
 
 Father_of_one_child_at_most or
 Father_of_two_children_at_most respectively.
 
 Your example is very illustrative. These things can happen
 in real life
 as well :)
 
 Csongor
 
 On 03/12/2014 03:56 PM, Marco Foroni wrote:
 > Hello, I have some doubts with max (and exactly)
 restriction in owl
 > protege and I'm looking for help. I would be very
 grateful if someone
 > could give me some advice.
 >
 > I created a specific example just to try to clarify my
 doubts but
 > without success. In my example, I created:
 > - two classes: Father and Child
 > - the Object Properties HasChild with domain Father and
 range Child
 > - 5 individuals: Father1, Father2 (type Father) and
 Child1, Child2,
 > Child3 (type Son) and the axioms: Father1 != Father2,
 Child1 != Child2
 > != Child3
 >
 > I specified Father1 HasChild Child1 and Father1
 HasChild Child2, and
 > Father2 HasChild Child3 so Father1 and Father2 are
 father of two
 > children at most and Father2 is father of one child at
 most.
 >
 > I also created two subclasses of Father (defined by
 equivalences with
 > the Class Expression Editor):
 > - Father_of_one_child_at_most  = Father and
 (HasChild max 1 Child)
 > - Father_of_two_children_at_most = Father and (HasChild
 max 2 HasChild)
 > When I start the reasoner Father1 and Father2 are not
 included in this
 > classes (while this problem does not occur with the
 minimum
 > restriction). Could someone help me, please?
 >
 >
 > _______________________________________________
 > protege-user mailing list
 > [hidden email]
 > https://mailman.stanford.edu/mailman/listinfo/protege-user
 
 -------------- next part --------------
 An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140312/e218f933/attachment-0001.html>
 
 ------------------------------
 
 Message: 3
 Date: Thu, 13 Mar 2014 07:34:40 +0100 (CET)
 From: F?zi, Peter <[hidden email]>
 To: User support for WebProtege and Protege Desktop
     <[hidden email]>
 Subject: Re: [protege-user] PrF Win - Import w Datamaster?
 Message-ID: <9693295.78.1394692476405.JavaMail.admin@MargLarJul>
 Content-Type: text/plain; charset="utf-8"
 
 ... My first trial-runs to import from Excel with Datamaster
 are succeed.
 Some experience noted for new users, see please below.
 Thank you, Samson.
 Regards, P?ter
 
 Notes:
 
     1. Datamaster wiki documentation contains two
 relevant document links ("... functionality of the
 DataMaster plug-in is available in the abstract for the
 presentation about DataMaster at the 10th International
 Protege Conference ... " ). Both of them is missing
     2. Wiki page for Excel driver (http://protegewiki.stanford.edu/wiki/XlSQL-Y8#Instructions_for_using_the_xlSQL-Y8_driver_with_DataMaster)
 indicates 'in edition' status . Still the explanation for
 the installation process is complete, it can be used in
 compliance with the purpose of the driver
     3. The very first step in using the driver is
 identification of the source data. If that is located on the
 PC hard disk folder, the user have to specify the folder
 name , NOT the filename !
     4. ... consequently: if this folder contains
 more Excel files, all of them will be found by the driver
 when [Connect] to that!
     5. For non-English language users: the driver
 ACCEPT Excel files containing local language characters in
 the filename , while
     6. ... IGNORES all sheets within the file ,
 which contain any single local (non-English) character in
 the first row of that sheet. The first row is expectably
 always the column name, it will be transformed to slot name
 in the ontology . So after my first trials, the import seems
 working for column names composed of English alphabet
 characters
     7. local characters within the captured data
 stream are transferred correctly , so the import preserves
 integrity of the input
 
 Meeting this experience, for a non-English user it seems
 wise to avoid use of local language characters in column-,
 sheet- and filenames to cope with the import. If it is of
 help, I contribute w testing the driver in a local language
 environment, and sharing my experience with the developers
 or with the community.
 Thanks with regards,
 P?ter
 
 
 ----- Eredeti ?zenet -----
 
 Felad?: "Peter F?zi" <[hidden email]>
 
 C?mzett: "User support for WebProtege and Protege Desktop"
 <[hidden email]>
 
 Elk?ld?tt ?zenetek: Szerda, 2014 M?rcius 12 6:46:27
 T?rgy: Re: [protege-user] PrF Win - Import w Datamaster?
 
 
 Thank you, Samson. Then I choose that.
 Peter
 
 ----- Eredeti ?zenet -----
 
 Felad?: "Samson Tu" <[hidden email]>
 
 C?mzett: "User support for WebProtege and Protege Desktop"
 <[hidden email]>
 
 Elk?ld?tt ?zenetek: Kedd, 2014 M?rcius 11 21:26:40
 T?rgy: Re: [protege-user] PrF Win - Import w Datamaster?
 
 Yes, Datamaster is a good way to import data.
 
 
 With best regards,
 Samson
 
 
 
 On Mar 11, 2014, at 1:12 PM, F?zi, Peter < [hidden email]
 > wrote:
 
 
 
 
 Hi,
 apology if my question left room for uncertainty.
 
 I need your help, whether plugin Datamaster -according to
 your experience- is a properly functioning tool for data
 import (Frame ontology target), or there is some other
 plugin or function which can be used more effectively for
 this purpose.
 
 Thanks for your hints in advance. Regards,
 Peter F?zi
 
 
 ----- Eredeti ?zenet -----
 
 Felad?: "Peter F?zi" < [hidden email]
 >
 C?mzett: "User support for WebProtege and Protege Desktop"
 < [hidden email]
 >
 Elk?ld?tt ?zenetek: H?tf?, 2014 M?rcius 10 22:45:03
 T?rgy: PrF Win - Import w Datamaster?
 
 
 Dear Community,
 
 I need to import external data into my ontology. Looking
 around, I found Datamaster plugin, which would support data
 import from Excel.
 
 Can you help me please with your practice? Is it fine to
 start with Datamaster, or there is another solution that
 should be preferred for any reason?
 
 Thank you w regards,
 Peter F?zi
 
 _______________________________________________
 protege-user mailing list
 [hidden email]
 
 https://mailman.stanford.edu/mailman/listinfo/protege-user
 
 
 
 
 _______________________________________________
 protege-user mailing list
 [hidden email]
 
 https://mailman.stanford.edu/mailman/listinfo/protege-user
 
 
 
 -------------- next part --------------
 An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140313/879b05e3/attachment.html>
 
 ------------------------------
 
 Subject: Digest Footer
 
 _______________________________________________
 protege-user mailing list
 [hidden email]
 https://mailman.stanford.edu/mailman/listinfo/protege-user
 
 
 ------------------------------
 
 End of protege-user Digest, Vol 2, Issue 23
 *******************************************
 
_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user
Reply | Threaded
Open this post in threaded view
|

Re: protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

Dave McComb
One way of thinking about the open world assumption is that the information you have is correct, but incomplete.

Given that, if you make a class of MarriedPerson and say it has min 1 spouse, when the reasoner finds an individual with at least one spouse it will infer that individual into the class.  Min works more or less as your intuition suggests, because even if you were to receive additional information, this person would still be married.

Now create the class MonogomousMarriedPerson and give it max 1 spouse.  Then create its complement, lets call it NotAMonogomousMarriedPerson, and its definition is: NOT MonogomouseMarriedPerson

Create an individual with two spouses (and assert that the individual spouse1 is differentFrom spouse2) and run the reasoner.

What is going on is the reasoner, seeing the two distinct spouses, essentially rules you out of the MonogomousMarriedPerson class (and normally you don't see what's happening unless you create a complement) but there it is (hopefully if I got my example right) inferred in to the NotAMonogomousMarriedPerson class (by the way that is an incomplete definition). The first individual you made is not ruled into either Monogomous nor NotMonogomous, because in the open world additional spouses may show up.  But once we have found the second distinct spouse that's enough to rule you out of monogamy and therefore into its complement.

Exactly is literally the same as saying max 1 and min 1 at the same time, and because of the affect that max has on the inference you get the same result.

This is how inference works to infer an individual into or out of a class.  The other use case is if you assert an individual into a class then you can use these axioms for some other purposes.

-----Original Message-----
From: protege-user [mailto:[hidden email]] On Behalf Of Sabina .
Sent: Thursday, March 13, 2014 2:40 AM
To: [hidden email]
Subject: Re: [protege-user] protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

Hi Marco,

the topic you raised also was on my mind during the last weeks. As Csongor put it correctly, the fact that the reasoner does not classify your individuals the way you expected is due to the so called Open World Assumption (OWA). However, what I still don't get is: how then, under the OWA do the cardinality restrictions make sense in an ontology? Aren't they basically ignored by the the reasoner in the process of classification? Could somebody share his/her insights?

Thanks a lot!

Sabina




--------------------------------------------
[hidden email] <[hidden email]> schrieb am Do, 13.3.2014:

 Betreff: protege-user Digest, Vol 2, Issue 23
 An: [hidden email]
 Datum: Donnerstag, 13. März, 2014 06:34 Uhr
 
 Send protege-user mailing list
 submissions to
     [hidden email]
 
 To subscribe or unsubscribe via the World Wide Web, visit
     https://mailman.stanford.edu/mailman/listinfo/protege-user
 or, via email, send a message with subject or body 'help'
 to
     [hidden email]
 
 You can reach the person managing the list at
     [hidden email]
 
 When replying, please edit your Subject line so it is more  specific  than "Re: Contents of protege-user digest..."
 
 
 Today's Topics:
 
    1. doubts with max (and exactly)
 restriction (Marco Foroni)
    2. Re: doubts with max (and exactly)  restriction (Csongor Nyulas)
    3. Re: PrF Win - Import w Datamaster?
 (F?zi)
 
 
 ----------------------------------------------------------------------
 
 Message: 1
 Date: Wed, 12 Mar 2014 23:56:53 +0100
 From: Marco Foroni <[hidden email]>
 To: [hidden email]
 Subject: [protege-user] doubts with max (and exactly)  restriction
 Message-ID:
     <[hidden email]>
 Content-Type: text/plain; charset="iso-8859-1"
 
 Hello, I have some doubts with max (and exactly) restriction  in owl protege  and I'm looking for help. I would be very grateful if  someone could give me  some advice.
 
 I created a specific example just to try to clarify my  doubts but without  success. In my example, I created:
 - two classes: Father and Child
 - the Object Properties HasChild with domain Father and  range Child
 - 5 individuals: Father1, Father2 (type Father) and Child1,  Child2, Child3  (type Son) and the axioms: Father1 != Father2, Child1 !=
 Child2 != Child3
 
 I specified Father1 HasChild Child1 and Father1 HasChild  Child2, and
 Father2 HasChild Child3 so Father1 and Father2 are father of  two children  at most and Father2 is father of one child at most.
 
 I also created two subclasses of Father (defined by  equivalences with the  Class Expression Editor):
 - Father_of_one_child_at_most  = Father and (HasChild  max 1 Child)
 - Father_of_two_children_at_most = Father and (HasChild max
 2 HasChild)
 When I start the reasoner Father1 and Father2 are not  included in this  classes (while this problem does not occur with the minimum  restriction).
 Could someone help me, please?
 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140312/523408d2/attachment-0001.html>
 
 ------------------------------
 
 Message: 2
 Date: Wed, 12 Mar 2014 16:15:11 -0700
 From: Csongor Nyulas <[hidden email]>
 To: [hidden email]
 Subject: Re: [protege-user] doubts with max (and exactly)  restriction
 Message-ID: <[hidden email]>
 Content-Type: text/plain; charset="iso-8859-1";  Format="flowed"
 
 Father1 and Father2 may have other children that are not  stated in this  ontology. This is why the reasoner can't classify them under
 
 Father_of_one_child_at_most or
 Father_of_two_children_at_most respectively.
 
 Your example is very illustrative. These things can happen  in real life  as well :)
 
 Csongor
 
 On 03/12/2014 03:56 PM, Marco Foroni wrote:
 > Hello, I have some doubts with max (and exactly)  restriction in owl  > protege and I'm looking for help. I would be very  grateful if someone  > could give me some advice.
 >
 > I created a specific example just to try to clarify my  doubts but  > without success. In my example, I created:
 > - two classes: Father and Child
 > - the Object Properties HasChild with domain Father and  range Child  > - 5 individuals: Father1, Father2 (type Father) and  Child1, Child2,  > Child3 (type Son) and the axioms: Father1 != Father2,
 Child1 != Child2
 > != Child3
 >
 > I specified Father1 HasChild Child1 and Father1  HasChild Child2, and  > Father2 HasChild Child3 so Father1 and Father2 are  father of two  > children at most and Father2 is father of one child at  most.
 >
 > I also created two subclasses of Father (defined by  equivalences with  > the Class Expression Editor):
 > - Father_of_one_child_at_most  = Father and  (HasChild max 1 Child)  > - Father_of_two_children_at_most = Father and (HasChild  max 2 HasChild)  > When I start the reasoner Father1 and Father2 are not  included in this  > classes (while this problem does not occur with the  minimum  > restriction). Could someone help me, please?
 >
 >
 > _______________________________________________
 > protege-user mailing list
 > [hidden email]
 > https://mailman.stanford.edu/mailman/listinfo/protege-user
 
 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140312/e218f933/attachment-0001.html>
 
 ------------------------------
 
 Message: 3
 Date: Thu, 13 Mar 2014 07:34:40 +0100 (CET)
 From: F?zi, Peter <[hidden email]>
 To: User support for WebProtege and Protege Desktop
     <[hidden email]>
 Subject: Re: [protege-user] PrF Win - Import w Datamaster?
 Message-ID: <9693295.78.1394692476405.JavaMail.admin@MargLarJul>
 Content-Type: text/plain; charset="utf-8"
 
 ... My first trial-runs to import from Excel with Datamaster  are succeed.
 Some experience noted for new users, see please below.
 Thank you, Samson.
 Regards, P?ter
 
 Notes:
 
     1. Datamaster wiki documentation contains two  relevant document links ("... functionality of the  DataMaster plug-in is available in the abstract for the  presentation about DataMaster at the 10th International  Protege Conference ... " ). Both of them is missing
     2. Wiki page for Excel driver (http://protegewiki.stanford.edu/wiki/XlSQL-Y8#Instructions_for_using_the_xlSQL-Y8_driver_with_DataMaster)
 indicates 'in edition' status . Still the explanation for  the installation process is complete, it can be used in  compliance with the purpose of the driver
     3. The very first step in using the driver is  identification of the source data. If that is located on the  PC hard disk folder, the user have to specify the folder  name , NOT the filename !
     4. ... consequently: if this folder contains  more Excel files, all of them will be found by the driver  when [Connect] to that!
     5. For non-English language users: the driver  ACCEPT Excel files containing local language characters in  the filename , while
     6. ... IGNORES all sheets within the file ,  which contain any single local (non-English) character in  the first row of that sheet. The first row is expectably  always the column name, it will be transformed to slot name  in the ontology . So after my first trials, the import seems  working for column names composed of English alphabet  characters
     7. local characters within the captured data  stream are transferred correctly , so the import preserves  integrity of the input
 
 Meeting this experience, for a non-English user it seems  wise to avoid use of local language characters in column-,
 sheet- and filenames to cope with the import. If it is of  help, I contribute w testing the driver in a local language  environment, and sharing my experience with the developers  or with the community.
 Thanks with regards,
 P?ter
 
 
 ----- Eredeti ?zenet -----
 
 Felad?: "Peter F?zi" <[hidden email]>
 
 C?mzett: "User support for WebProtege and Protege Desktop"
 <[hidden email]>
 
 Elk?ld?tt ?zenetek: Szerda, 2014 M?rcius 12 6:46:27
 T?rgy: Re: [protege-user] PrF Win - Import w Datamaster?
 
 
 Thank you, Samson. Then I choose that.
 Peter
 
 ----- Eredeti ?zenet -----
 
 Felad?: "Samson Tu" <[hidden email]>
 
 C?mzett: "User support for WebProtege and Protege Desktop"
 <[hidden email]>
 
 Elk?ld?tt ?zenetek: Kedd, 2014 M?rcius 11 21:26:40
 T?rgy: Re: [protege-user] PrF Win - Import w Datamaster?
 
 Yes, Datamaster is a good way to import data.
 
 
 With best regards,
 Samson
 
 
 
 On Mar 11, 2014, at 1:12 PM, F?zi, Peter < [hidden email]  > wrote:
 
 
 
 
 Hi,
 apology if my question left room for uncertainty.
 
 I need your help, whether plugin Datamaster -according to  your experience- is a properly functioning tool for data  import (Frame ontology target), or there is some other  plugin or function which can be used more effectively for  this purpose.
 
 Thanks for your hints in advance. Regards,  Peter F?zi
 
 
 ----- Eredeti ?zenet -----
 
 Felad?: "Peter F?zi" < [hidden email]  >
 C?mzett: "User support for WebProtege and Protege Desktop"
 < [hidden email]
 >
 Elk?ld?tt ?zenetek: H?tf?, 2014 M?rcius 10 22:45:03
 T?rgy: PrF Win - Import w Datamaster?
 
 
 Dear Community,
 
 I need to import external data into my ontology. Looking  around, I found Datamaster plugin, which would support data  import from Excel.
 
 Can you help me please with your practice? Is it fine to  start with Datamaster, or there is another solution that  should be preferred for any reason?
 
 Thank you w regards,
 Peter F?zi
 
 _______________________________________________
 protege-user mailing list
 [hidden email]
 
 https://mailman.stanford.edu/mailman/listinfo/protege-user
 
 
 
 
 _______________________________________________
 protege-user mailing list
 [hidden email]
 
 https://mailman.stanford.edu/mailman/listinfo/protege-user
 
 
 
 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140313/879b05e3/attachment.html>
 
 ------------------------------
 
 Subject: Digest Footer
 
 _______________________________________________
 protege-user mailing list
 [hidden email]
 https://mailman.stanford.edu/mailman/listinfo/protege-user
 
 
 ------------------------------
 
 End of protege-user Digest, Vol 2, Issue 23
 *******************************************
 
_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user
_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user
Reply | Threaded
Open this post in threaded view
|

Re: protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

Marco
Thank you Dave. With your help I understand how the reasoner works in case of minimum restriction (due to the fact that the OWA has no influence in a min restriction), and I also extended my scenario with your hints:

I created a class NotFatherOfOneChildAtMost as not FatherOfOneChildAtMost. I've seen when I started the reasoner that Father1 (that one with two child) is correctly inferred in NotFatherOfOneChildAtMost (since the two children of Father1 are different).

If I may ask, is there a way to tell the reasoner that one individual has no other occurrences in a certain object properties? Or maybe tell that in a certain class there is no other individuals?


2014-03-13 15:58 GMT+01:00 Dave McComb <[hidden email]>:
One way of thinking about the open world assumption is that the information you have is correct, but incomplete.

Given that, if you make a class of MarriedPerson and say it has min 1 spouse, when the reasoner finds an individual with at least one spouse it will infer that individual into the class.  Min works more or less as your intuition suggests, because even if you were to receive additional information, this person would still be married.

Now create the class MonogomousMarriedPerson and give it max 1 spouse.  Then create its complement, lets call it NotAMonogomousMarriedPerson, and its definition is: NOT MonogomouseMarriedPerson

Create an individual with two spouses (and assert that the individual spouse1 is differentFrom spouse2) and run the reasoner.

What is going on is the reasoner, seeing the two distinct spouses, essentially rules you out of the MonogomousMarriedPerson class (and normally you don't see what's happening unless you create a complement) but there it is (hopefully if I got my example right) inferred in to the NotAMonogomousMarriedPerson class (by the way that is an incomplete definition). The first individual you made is not ruled into either Monogomous nor NotMonogomous, because in the open world additional spouses may show up.  But once we have found the second distinct spouse that's enough to rule you out of monogamy and therefore into its complement.

Exactly is literally the same as saying max 1 and min 1 at the same time, and because of the affect that max has on the inference you get the same result.

This is how inference works to infer an individual into or out of a class.  The other use case is if you assert an individual into a class then you can use these axioms for some other purposes.

-----Original Message-----
From: protege-user [mailto:[hidden email]] On Behalf Of Sabina .
Sent: Thursday, March 13, 2014 2:40 AM
To: [hidden email]
Subject: Re: [protege-user] protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

Hi Marco,

the topic you raised also was on my mind during the last weeks. As Csongor put it correctly, the fact that the reasoner does not classify your individuals the way you expected is due to the so called Open World Assumption (OWA). However, what I still don't get is: how then, under the OWA do the cardinality restrictions make sense in an ontology? Aren't they basically ignored by the the reasoner in the process of classification? Could somebody share his/her insights?

Thanks a lot!

Sabina




--------------------------------------------
[hidden email] <[hidden email]> schrieb am Do, 13.3.2014:

 Betreff: protege-user Digest, Vol 2, Issue 23
 An: [hidden email]
 Datum: Donnerstag, 13. März, 2014 06:34 Uhr

 Send protege-user mailing list
 submissions to
     [hidden email]

 To subscribe or unsubscribe via the World Wide Web, visit
     https://mailman.stanford.edu/mailman/listinfo/protege-user
 or, via email, send a message with subject or body 'help'
 to
     [hidden email]

 You can reach the person managing the list at
     [hidden email]

 When replying, please edit your Subject line so it is more  specific  than "Re: Contents of protege-user digest..."


 Today's Topics:

    1. doubts with max (and exactly)
 restriction (Marco Foroni)
    2. Re: doubts with max (and exactly)  restriction (Csongor Nyulas)
    3. Re: PrF Win - Import w Datamaster?
 (F?zi)


 ----------------------------------------------------------------------

 Message: 1
 Date: Wed, 12 Mar 2014 23:56:53 +0100
 From: Marco Foroni <[hidden email]>
 To: [hidden email]
 Subject: [protege-user] doubts with max (and exactly)  restriction
 Message-ID:
     <[hidden email]>
 Content-Type: text/plain; charset="iso-8859-1"

 Hello, I have some doubts with max (and exactly) restriction  in owl protege  and I'm looking for help. I would be very grateful if  someone could give me  some advice.

 I created a specific example just to try to clarify my  doubts but without  success. In my example, I created:
 - two classes: Father and Child
 - the Object Properties HasChild with domain Father and  range Child
 - 5 individuals: Father1, Father2 (type Father) and Child1,  Child2, Child3  (type Son) and the axioms: Father1 != Father2, Child1 !=
 Child2 != Child3

 I specified Father1 HasChild Child1 and Father1 HasChild  Child2, and
 Father2 HasChild Child3 so Father1 and Father2 are father of  two children  at most and Father2 is father of one child at most.

 I also created two subclasses of Father (defined by  equivalences with the  Class Expression Editor):
 - Father_of_one_child_at_most  = Father and (HasChild  max 1 Child)
 - Father_of_two_children_at_most = Father and (HasChild max
 2 HasChild)
 When I start the reasoner Father1 and Father2 are not  included in this  classes (while this problem does not occur with the minimum  restriction).
 Could someone help me, please?
 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140312/523408d2/attachment-0001.html>

 ------------------------------

 Message: 2
 Date: Wed, 12 Mar 2014 16:15:11 -0700
 From: Csongor Nyulas <[hidden email]>
 To: [hidden email]
 Subject: Re: [protege-user] doubts with max (and exactly)  restriction
 Message-ID: <[hidden email]>
 Content-Type: text/plain; charset="iso-8859-1";  Format="flowed"

 Father1 and Father2 may have other children that are not  stated in this  ontology. This is why the reasoner can't classify them under

 Father_of_one_child_at_most or
 Father_of_two_children_at_most respectively.

 Your example is very illustrative. These things can happen  in real life  as well :)

 Csongor

 On 03/12/2014 03:56 PM, Marco Foroni wrote:
 > Hello, I have some doubts with max (and exactly)  restriction in owl  > protege and I'm looking for help. I would be very  grateful if someone  > could give me some advice.
 >
 > I created a specific example just to try to clarify my  doubts but  > without success. In my example, I created:
 > - two classes: Father and Child
 > - the Object Properties HasChild with domain Father and  range Child  > - 5 individuals: Father1, Father2 (type Father) and  Child1, Child2,  > Child3 (type Son) and the axioms: Father1 != Father2,
 Child1 != Child2
 > != Child3
 >
 > I specified Father1 HasChild Child1 and Father1  HasChild Child2, and  > Father2 HasChild Child3 so Father1 and Father2 are  father of two  > children at most and Father2 is father of one child at  most.
 >
 > I also created two subclasses of Father (defined by  equivalences with  > the Class Expression Editor):
 > - Father_of_one_child_at_most  = Father and  (HasChild max 1 Child)  > - Father_of_two_children_at_most = Father and (HasChild  max 2 HasChild)  > When I start the reasoner Father1 and Father2 are not  included in this  > classes (while this problem does not occur with the  minimum  > restriction). Could someone help me, please?
 >
 >
 > _______________________________________________
 > protege-user mailing list
 > [hidden email]
 > https://mailman.stanford.edu/mailman/listinfo/protege-user

 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140312/e218f933/attachment-0001.html>

 ------------------------------

 Message: 3
 Date: Thu, 13 Mar 2014 07:34:40 +0100 (CET)
 From: F?zi, Peter <[hidden email]>
 To: User support for WebProtege and Protege Desktop
     <[hidden email]>
 Subject: Re: [protege-user] PrF Win - Import w Datamaster?
 Message-ID: <9693295.78.1394692476405.JavaMail.admin@MargLarJul>
 Content-Type: text/plain; charset="utf-8"

 ... My first trial-runs to import from Excel with Datamaster  are succeed.
 Some experience noted for new users, see please below.
 Thank you, Samson.
 Regards, P?ter

 Notes:

     1. Datamaster wiki documentation contains two  relevant document links ("... functionality of the  DataMaster plug-in is available in the abstract for the  presentation about DataMaster at the 10th International  Protege Conference ... " ). Both of them is missing
     2. Wiki page for Excel driver (http://protegewiki.stanford.edu/wiki/XlSQL-Y8#Instructions_for_using_the_xlSQL-Y8_driver_with_DataMaster)
 indicates 'in edition' status . Still the explanation for  the installation process is complete, it can be used in  compliance with the purpose of the driver
     3. The very first step in using the driver is  identification of the source data. If that is located on the  PC hard disk folder, the user have to specify the folder  name , NOT the filename !
     4. ... consequently: if this folder contains  more Excel files, all of them will be found by the driver  when [Connect] to that!
     5. For non-English language users: the driver  ACCEPT Excel files containing local language characters in  the filename , while
     6. ... IGNORES all sheets within the file ,  which contain any single local (non-English) character in  the first row of that sheet. The first row is expectably  always the column name, it will be transformed to slot name  in the ontology . So after my first trials, the import seems  working for column names composed of English alphabet  characters
     7. local characters within the captured data  stream are transferred correctly , so the import preserves  integrity of the input

 Meeting this experience, for a non-English user it seems  wise to avoid use of local language characters in column-,
 sheet- and filenames to cope with the import. If it is of  help, I contribute w testing the driver in a local language  environment, and sharing my experience with the developers  or with the community.
 Thanks with regards,
 P?ter


 ----- Eredeti ?zenet -----

 Felad?: "Peter F?zi" <[hidden email]>

 C?mzett: "User support for WebProtege and Protege Desktop"
 <[hidden email]>

 Elk?ld?tt ?zenetek: Szerda, 2014 M?rcius 12 6:46:27
 T?rgy: Re: [protege-user] PrF Win - Import w Datamaster?


 Thank you, Samson. Then I choose that.
 Peter

 ----- Eredeti ?zenet -----

 Felad?: "Samson Tu" <[hidden email]>

 C?mzett: "User support for WebProtege and Protege Desktop"
 <[hidden email]>

 Elk?ld?tt ?zenetek: Kedd, 2014 M?rcius 11 21:26:40
 T?rgy: Re: [protege-user] PrF Win - Import w Datamaster?

 Yes, Datamaster is a good way to import data.


 With best regards,
 Samson



 On Mar 11, 2014, at 1:12 PM, F?zi, Peter < [hidden email]  > wrote:




 Hi,
 apology if my question left room for uncertainty.

 I need your help, whether plugin Datamaster -according to  your experience- is a properly functioning tool for data  import (Frame ontology target), or there is some other  plugin or function which can be used more effectively for  this purpose.

 Thanks for your hints in advance. Regards,  Peter F?zi


 ----- Eredeti ?zenet -----

 Felad?: "Peter F?zi" < [hidden email]  >
 C?mzett: "User support for WebProtege and Protege Desktop"
 < [hidden email]
 >
 Elk?ld?tt ?zenetek: H?tf?, 2014 M?rcius 10 22:45:03
 T?rgy: PrF Win - Import w Datamaster?


 Dear Community,

 I need to import external data into my ontology. Looking  around, I found Datamaster plugin, which would support data  import from Excel.

 Can you help me please with your practice? Is it fine to  start with Datamaster, or there is another solution that  should be preferred for any reason?

 Thank you w regards,
 Peter F?zi

 _______________________________________________
 protege-user mailing list
 [hidden email]

 https://mailman.stanford.edu/mailman/listinfo/protege-user




 _______________________________________________
 protege-user mailing list
 [hidden email]

 https://mailman.stanford.edu/mailman/listinfo/protege-user



 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140313/879b05e3/attachment.html>

 ------------------------------

 Subject: Digest Footer

 _______________________________________________
 protege-user mailing list
 [hidden email]
 https://mailman.stanford.edu/mailman/listinfo/protege-user


 ------------------------------

 End of protege-user Digest, Vol 2, Issue 23
 *******************************************

_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user
_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user


_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user
Reply | Threaded
Open this post in threaded view
|

Re: protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

Dave McComb

Yes, but you’re probably not going to like it.

 

I think you want the axioms to act like a guard, as constraints do in a relational database.  But there isn’t a mechanism in OWL for constraining input (there have been tools built, and I think any useful business application would employ such techniques, but this isn’t inherent in OWL)

 

To your first question: making the property hasChild functional, says that the subject (father in this case) can have only one object via this property (the child).  However when you try this, this is what you will find: when you add the second child, the reasoner will assume the two children must be just different URIs for the same person.  If you insist that they are not (owl:differentFrom) you will get an inconsistent ontology.

 

You wouldn’t use functional in this case.  However, there are cases where it makes sense:  hasBiologicalMother for instance.

 

On your second question, using the enum, or “oneOf” definition for a class, defines the class in terms of its members, and prevents new members from being inferred.  We could define the founding fathers as the signers of the declaration, and no amount of inference would get anyone else in that set. 

 

A last resort: you can make your class a subclass of a class with exactly 2 children, but you’ll get an inconsistent ontology if you have a instance with more than 2

 

From: protege-user [mailto:[hidden email]] On Behalf Of Marco Foroni
Sent: Thursday, March 13, 2014 1:49 PM
To: User support for WebProtege and Protege Desktop
Subject: Re: [protege-user] protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

 

Thank you Dave. With your help I understand how the reasoner works in case of minimum restriction (due to the fact that the OWA has no influence in a min restriction), and I also extended my scenario with your hints:

 

I created a class NotFatherOfOneChildAtMost as not FatherOfOneChildAtMost. I've seen when I started the reasoner that Father1 (that one with two child) is correctly inferred in NotFatherOfOneChildAtMost (since the two children of Father1 are different).

 

If I may ask, is there a way to tell the reasoner that one individual has no other occurrences in a certain object properties? Or maybe tell that in a certain class there is no other individuals?

 

2014-03-13 15:58 GMT+01:00 Dave McComb <[hidden email]>:

One way of thinking about the open world assumption is that the information you have is correct, but incomplete.

Given that, if you make a class of MarriedPerson and say it has min 1 spouse, when the reasoner finds an individual with at least one spouse it will infer that individual into the class.  Min works more or less as your intuition suggests, because even if you were to receive additional information, this person would still be married.

Now create the class MonogomousMarriedPerson and give it max 1 spouse.  Then create its complement, lets call it NotAMonogomousMarriedPerson, and its definition is: NOT MonogomouseMarriedPerson

Create an individual with two spouses (and assert that the individual spouse1 is differentFrom spouse2) and run the reasoner.

What is going on is the reasoner, seeing the two distinct spouses, essentially rules you out of the MonogomousMarriedPerson class (and normally you don't see what's happening unless you create a complement) but there it is (hopefully if I got my example right) inferred in to the NotAMonogomousMarriedPerson class (by the way that is an incomplete definition). The first individual you made is not ruled into either Monogomous nor NotMonogomous, because in the open world additional spouses may show up.  But once we have found the second distinct spouse that's enough to rule you out of monogamy and therefore into its complement.

Exactly is literally the same as saying max 1 and min 1 at the same time, and because of the affect that max has on the inference you get the same result.

This is how inference works to infer an individual into or out of a class.  The other use case is if you assert an individual into a class then you can use these axioms for some other purposes.


-----Original Message-----
From: protege-user [mailto:[hidden email]] On Behalf Of Sabina .
Sent: Thursday, March 13, 2014 2:40 AM
To: [hidden email]

Subject: Re: [protege-user] protege-user Digest, Vol 2, Issue 23, re: Marco's message: doubts with max (and exactly) restriction

Hi Marco,

the topic you raised also was on my mind during the last weeks. As Csongor put it correctly, the fact that the reasoner does not classify your individuals the way you expected is due to the so called Open World Assumption (OWA). However, what I still don't get is: how then, under the OWA do the cardinality restrictions make sense in an ontology? Aren't they basically ignored by the the reasoner in the process of classification? Could somebody share his/her insights?

Thanks a lot!

Sabina




--------------------------------------------
[hidden email] <[hidden email]> schrieb am Do, 13.3.2014:

 Betreff: protege-user Digest, Vol 2, Issue 23
 An: [hidden email]
 Datum: Donnerstag, 13. März, 2014 06:34 Uhr

 Send protege-user mailing list
 submissions to
     [hidden email]

 To subscribe or unsubscribe via the World Wide Web, visit
     https://mailman.stanford.edu/mailman/listinfo/protege-user
 or, via email, send a message with subject or body 'help'
 to
     [hidden email]

 You can reach the person managing the list at
     [hidden email]

 When replying, please edit your Subject line so it is more  specific  than "Re: Contents of protege-user digest..."


 Today's Topics:

    1. doubts with max (and exactly)
 restriction (Marco Foroni)
    2. Re: doubts with max (and exactly)  restriction (Csongor Nyulas)
    3. Re: PrF Win - Import w Datamaster?
 (F?zi)


 ----------------------------------------------------------------------

 Message: 1
 Date: Wed, 12 Mar 2014 23:56:53 +0100
 From: Marco Foroni <[hidden email]>
 To: [hidden email]
 Subject: [protege-user] doubts with max (and exactly)  restriction
 Message-ID:
     <[hidden email]>
 Content-Type: text/plain; charset="iso-8859-1"

 Hello, I have some doubts with max (and exactly) restriction  in owl protege  and I'm looking for help. I would be very grateful if  someone could give me  some advice.

 I created a specific example just to try to clarify my  doubts but without  success. In my example, I created:
 - two classes: Father and Child
 - the Object Properties HasChild with domain Father and  range Child
 - 5 individuals: Father1, Father2 (type Father) and Child1,  Child2, Child3  (type Son) and the axioms: Father1 != Father2, Child1 !=
 Child2 != Child3

 I specified Father1 HasChild Child1 and Father1 HasChild  Child2, and
 Father2 HasChild Child3 so Father1 and Father2 are father of  two children  at most and Father2 is father of one child at most.

 I also created two subclasses of Father (defined by  equivalences with the  Class Expression Editor):
 - Father_of_one_child_at_most  = Father and (HasChild  max 1 Child)
 - Father_of_two_children_at_most = Father and (HasChild max
 2 HasChild)
 When I start the reasoner Father1 and Father2 are not  included in this  classes (while this problem does not occur with the minimum  restriction).
 Could someone help me, please?
 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140312/523408d2/attachment-0001.html>

 ------------------------------

 Message: 2
 Date: Wed, 12 Mar 2014 16:15:11 -0700
 From: Csongor Nyulas <[hidden email]>
 To: [hidden email]
 Subject: Re: [protege-user] doubts with max (and exactly)  restriction
 Message-ID: <[hidden email]>
 Content-Type: text/plain; charset="iso-8859-1";  Format="flowed"

 Father1 and Father2 may have other children that are not  stated in this  ontology. This is why the reasoner can't classify them under

 Father_of_one_child_at_most or
 Father_of_two_children_at_most respectively.

 Your example is very illustrative. These things can happen  in real life  as well :)

 Csongor

 On 03/12/2014 03:56 PM, Marco Foroni wrote:
 > Hello, I have some doubts with max (and exactly)  restriction in owl  > protege and I'm looking for help. I would be very  grateful if someone  > could give me some advice.
 >
 > I created a specific example just to try to clarify my  doubts but  > without success. In my example, I created:
 > - two classes: Father and Child
 > - the Object Properties HasChild with domain Father and  range Child  > - 5 individuals: Father1, Father2 (type Father) and  Child1, Child2,  > Child3 (type Son) and the axioms: Father1 != Father2,
 Child1 != Child2
 > != Child3
 >
 > I specified Father1 HasChild Child1 and Father1  HasChild Child2, and  > Father2 HasChild Child3 so Father1 and Father2 are  father of two  > children at most and Father2 is father of one child at  most.
 >
 > I also created two subclasses of Father (defined by  equivalences with  > the Class Expression Editor):
 > - Father_of_one_child_at_most  = Father and  (HasChild max 1 Child)  > - Father_of_two_children_at_most = Father and (HasChild  max 2 HasChild)  > When I start the reasoner Father1 and Father2 are not  included in this  > classes (while this problem does not occur with the  minimum  > restriction). Could someone help me, please?
 >
 >
 > _______________________________________________
 > protege-user mailing list
 > [hidden email]
 > https://mailman.stanford.edu/mailman/listinfo/protege-user

 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140312/e218f933/attachment-0001.html>

 ------------------------------

 Message: 3
 Date: Thu, 13 Mar 2014 07:34:40 +0100 (CET)
 From: F?zi, Peter <[hidden email]>
 To: User support for WebProtege and Protege Desktop
     <[hidden email]>
 Subject: Re: [protege-user] PrF Win - Import w Datamaster?
 Message-ID: <[hidden email]>
 Content-Type: text/plain; charset="utf-8"

 ... My first trial-runs to import from Excel with Datamaster  are succeed.
 Some experience noted for new users, see please below.
 Thank you, Samson.
 Regards, P?ter

 Notes:

     1. Datamaster wiki documentation contains two  relevant document links ("... functionality of the  DataMaster plug-in is available in the abstract for the  presentation about DataMaster at the 10th International  Protege Conference ... " ). Both of them is missing
     2. Wiki page for Excel driver (http://protegewiki.stanford.edu/wiki/XlSQL-Y8#Instructions_for_using_the_xlSQL-Y8_driver_with_DataMaster)
 indicates 'in edition' status . Still the explanation for  the installation process is complete, it can be used in  compliance with the purpose of the driver
     3. The very first step in using the driver is  identification of the source data. If that is located on the  PC hard disk folder, the user have to specify the folder  name , NOT the filename !
     4. ... consequently: if this folder contains  more Excel files, all of them will be found by the driver  when [Connect] to that!
     5. For non-English language users: the driver  ACCEPT Excel files containing local language characters in  the filename , while
     6. ... IGNORES all sheets within the file ,  which contain any single local (non-English) character in  the first row of that sheet. The first row is expectably  always the column name, it will be transformed to slot name  in the ontology . So after my first trials, the import seems  working for column names composed of English alphabet  characters
     7. local characters within the captured data  stream are transferred correctly , so the import preserves  integrity of the input

 Meeting this experience, for a non-English user it seems  wise to avoid use of local language characters in column-,
 sheet- and filenames to cope with the import. If it is of  help, I contribute w testing the driver in a local language  environment, and sharing my experience with the developers  or with the community.
 Thanks with regards,
 P?ter


 ----- Eredeti ?zenet -----

 Felad?: "Peter F?zi" <[hidden email]>

 C?mzett: "User support for WebProtege and Protege Desktop"
 <[hidden email]>

 Elk?ld?tt ?zenetek: Szerda, 2014 M?rcius 12 6:46:27
 T?rgy: Re: [protege-user] PrF Win - Import w Datamaster?


 Thank you, Samson. Then I choose that.
 Peter

 ----- Eredeti ?zenet -----

 Felad?: "Samson Tu" <[hidden email]>

 C?mzett: "User support for WebProtege and Protege Desktop"
 <[hidden email]>

 Elk?ld?tt ?zenetek: Kedd, 2014 M?rcius 11 21:26:40
 T?rgy: Re: [protege-user] PrF Win - Import w Datamaster?

 Yes, Datamaster is a good way to import data.


 With best regards,
 Samson



 On Mar 11, 2014, at 1:12 PM, F?zi, Peter < [hidden email]  > wrote:




 Hi,
 apology if my question left room for uncertainty.

 I need your help, whether plugin Datamaster -according to  your experience- is a properly functioning tool for data  import (Frame ontology target), or there is some other  plugin or function which can be used more effectively for  this purpose.

 Thanks for your hints in advance. Regards,  Peter F?zi


 ----- Eredeti ?zenet -----

 Felad?: "Peter F?zi" < [hidden email]  >
 C?mzett: "User support for WebProtege and Protege Desktop"
 < [hidden email]
 >
 Elk?ld?tt ?zenetek: H?tf?, 2014 M?rcius 10 22:45:03
 T?rgy: PrF Win - Import w Datamaster?


 Dear Community,

 I need to import external data into my ontology. Looking  around, I found Datamaster plugin, which would support data  import from Excel.

 Can you help me please with your practice? Is it fine to  start with Datamaster, or there is another solution that  should be preferred for any reason?

 Thank you w regards,
 Peter F?zi

 _______________________________________________
 protege-user mailing list
 [hidden email]

 https://mailman.stanford.edu/mailman/listinfo/protege-user




 _______________________________________________
 protege-user mailing list
 [hidden email]

 https://mailman.stanford.edu/mailman/listinfo/protege-user



 -------------- next part --------------  An HTML attachment was scrubbed...
 URL: <http://mailman.stanford.edu/pipermail/protege-user/attachments/20140313/879b05e3/attachment.html>

 ------------------------------

 Subject: Digest Footer

 _______________________________________________
 protege-user mailing list
 [hidden email]
 https://mailman.stanford.edu/mailman/listinfo/protege-user


 ------------------------------

 End of protege-user Digest, Vol 2, Issue 23
 *******************************************

_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user
_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user

 


_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user