Quantcast

Could I use SWRL rules to determine whether a object property is a symmetric property?

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Could I use SWRL rules to determine whether a object property is a symmetric property?

simon_wangcheng
Hi everyone!

I'm trying to use SWRL rules to determing whether a object property is symmetric. I found a expression like this "isSymmetricProperty(hasRelationWith)" on an article. However, when I type a similar expression in SWRLTab which version is 1.1.4 on Protege 5.0, the plugin recognize "isSymmetricProperty" as "invalid SWRL atom predicate".

 Google privdes me a web which shows some individuals about swrl:Builtin, "tbox:isSymmetricProerty" is found, what' more there are many predicates that I don't find before on w3c web. So now, I'm very confued about this.

Could anybody help me?

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

Re: Could I use SWRL rules to determine whether a object property is a symmetric property?

samsontu
Hi,

You can’t expect an implementation of SWRL to support a predicate mentioned in a random article or web page.

You can find the documentation for Protege’s SWRL implementation at [1]. The page on tbox built-ins [2] doesn’t mention any “tbox:isSymmetricProperty”.

You can find the documentation on Pellet’s support of SWRL builtins here [3]. No tbox:isSymmetricProperty.

Conclusion: You can’t use SWRL rules to determine whether a object property is symmetric with these two SWRL implementations.

With best regards,
Samson



On Mar 14, 2017, at 8:04 PM, 王诚 <[hidden email]> wrote:

Hi everyone!

I'm trying to use SWRL rules to determing whether a object property is symmetric. I found a expression like this "isSymmetricProperty(hasRelationWith)" on an article. However, when I type a similar expression in SWRLTab which version is 1.1.4 on Protege 5.0, the plugin recognize "isSymmetricProperty" as "invalid SWRL atom predicate".

 Google privdes me a web which shows some individuals about swrl:Builtin, "tbox:isSymmetricProerty" is found, what' more there are many predicates that I don't find before on w3c web. So now, I'm very confued about this.

Could anybody help me?
_______________________________________________
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
|  
Report Content as Inappropriate

Re: Could I use SWRL rules to determine whether a object property is a symmetric property?

Lorenz Buehmann
But you can extend it by your own custom built-in :D
That's the way to go

Hi,

You can’t expect an implementation of SWRL to support a predicate mentioned in a random article or web page.

You can find the documentation for Protege’s SWRL implementation at [1]. The page on tbox built-ins [2] doesn’t mention any “tbox:isSymmetricProperty”.

You can find the documentation on Pellet’s support of SWRL builtins here [3]. No tbox:isSymmetricProperty.

Conclusion: You can’t use SWRL rules to determine whether a object property is symmetric with these two SWRL implementations.

With best regards,
Samson



On Mar 14, 2017, at 8:04 PM, 王诚 <[hidden email]> wrote:

Hi everyone!

I'm trying to use SWRL rules to determing whether a object property is symmetric. I found a expression like this "isSymmetricProperty(hasRelationWith)" on an article. However, when I type a similar expression in SWRLTab which version is 1.1.4 on Protege 5.0, the plugin recognize "isSymmetricProperty" as "invalid SWRL atom predicate".

 Google privdes me a web which shows some individuals about swrl:Builtin, "tbox:isSymmetricProerty" is found, what' more there are many predicates that I don't find before on w3c web. So now, I'm very confued about this.

Could anybody help me?
_______________________________________________
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
-- 
Lorenz Bühmann
AKSW group, University of Leipzig
Group: http://aksw.org - semantic web research center

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

Re: Could I use SWRL rules to determine whether a object property is a symmetric property?

simon_wangcheng
Hi!
I find a page[1] on protege'web which gives the usage of isSymmetricProperty:

isSymmetricProperty(List<BuiltInArgument> arguments)
    Determine if a single property argument is symmetric.


It seems that SWRL tbox once provided a method to determin if a property is symmtric. What's more, there is a page[2] shows java code of this method. Unfortunately,  the dependency packages are changed compared with latest swrlapi.

Obviously, SWRL experiences a significant change. Only a few core built-ins mentioned by w3c[3] were saved, others were removed.



 public boolean isSymmetricProperty(List<BuiltInArgument> arguments) throws BuiltInException
  {
    checkNumberOfArgumentsEqualTo(1, arguments.size());
    String propertyURI = getArgumentAsAPropertyURI(0, arguments);

    boolean result = false;
    try {
      result = SWRLOWLUtil.isOWLSymmetricProperty(getOWLModel(), propertyURI, true);
    } catch (SWRLOWLUtilException e) {
      throw new BuiltInException(e.getMessage());
    } // try

    return result;
  }









[1]http://protege.stanford.edu/protege/3.4/docs/api/owl/edu/stanford/smi/protegex/owl/swrl/bridge/builtins/tbox/SWRLBuiltInLibraryImpl.html#isClassDescription(java.util.List)

[2]https://searchcode.com/codesearch/view/77747074/

[3]https://www.w3.org/Submission/SWRL/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Could I use SWRL rules to determine whether a object property is a symmetric property?

Lorenz Buehmann
As I said, feel free to

1. fork the Github project,
2. add the built-in
3. open a pull request



Hi!
I find a page[1] on protege'web which gives the usage of
*isSymmetricProperty*:

/isSymmetricProperty(List<BuiltInArgument> arguments) 
    Determine if a single property argument is symmetric./

It seems that SWRL tbox once provided a method to determin if a property is
symmtric. What's more, there is a page[2] shows java code of this method.
Unfortunately,  the dependency packages are changed compared with latest
swrlapi.

Obviously, SWRL experiences a significant change. Only a few core built-ins
mentioned by w3c[3] were saved, others were removed.



/ public boolean isSymmetricProperty(List<BuiltInArgument> arguments) throws
BuiltInException
  {
    checkNumberOfArgumentsEqualTo(1, arguments.size());
    String propertyURI = getArgumentAsAPropertyURI(0, arguments);

    boolean result = false;
    try {
      result = SWRLOWLUtil.isOWLSymmetricProperty(getOWLModel(),
propertyURI, true);
    } catch (SWRLOWLUtilException e) {
      throw new BuiltInException(e.getMessage());
    } // try

    return result;
  } /








[1]
http://protege.stanford.edu/protege/3.4/docs/api/owl/edu/stanford/smi/protegex/owl/swrl/bridge/builtins/tbox/SWRLBuiltInLibraryImpl.html#isClassDescription(java.util.List)
<http://protege.stanford.edu/protege/3.4/docs/api/owl/edu/stanford/smi/protegex/owl/swrl/bridge/builtins/tbox/SWRLBuiltInLibraryImpl.html#isClassDescription(java.util.List)>  

[2] https://searchcode.com/codesearch/view/77747074/
<https://searchcode.com/codesearch/view/77747074/>  

[3] https://www.w3.org/Submission/SWRL/
<https://www.w3.org/Submission/SWRL/>  



--
View this message in context: http://protege-project.136.n4.nabble.com/Could-I-use-SWRL-rules-to-determine-whether-a-object-property-is-a-symmetric-property-tp4667824p4667837.html
Sent from the Protege User mailing list archive at Nabble.com.
_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user

-- 
Lorenz Bühmann
AKSW group, University of Leipzig
Group: http://aksw.org - semantic web research center

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

Re: Could I use SWRL rules to determine whether a object property is a symmetric property?

simon_wangcheng
Thanks a lot!
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Could I use SWRL rules to determine whether a object property is a symmetric property?

Igor Toujilov-2
In reply to this post by Lorenz Buehmann

Hi Simon,

You refer to a very old implementation in Protégé 3, which is a frame-based system, and not maintained any more. Modern Protégé 4 and 5 are completely different, and based on OWL 2 DL (description logics).

The new systems use so called safe SWRL, which preserve OWL 2 DL decidability. That means you cannot bind an object property expression to an SWRL variable. You only can bind an individual or a literal to an SWLR variable. That means you cannot have an SWLR built-in for detecting a symmetric property in principal.

 

Hi Lorenz,

Implementing such a custom built-in is also fundamentally impossible in safe SWRL because of the generic meaning of detecting the property symmetry for infinite number of individuals. Safe SWRL can only infer a class membership or a property value for individuals.

 

Cheers,

Igor

 

 
 
Sent: Wednesday, March 15, 2017 at 9:00 AM
From: "Lorenz B." <[hidden email]>
To: [hidden email]
Subject: Re: [protege-user] Could I use SWRL rules to determine whether a object property is a symmetric property?
As I said, feel free to

1. fork the Github project,
2. add the built-in
3. open a pull request

 
 
Hi!
I find a page[1] on protege'web which gives the usage of
*isSymmetricProperty*:

/isSymmetricProperty(List<BuiltInArgument> arguments) 
    Determine if a single property argument is symmetric./

It seems that SWRL tbox once provided a method to determin if a property is
symmtric. What's more, there is a page[2] shows java code of this method.
Unfortunately,  the dependency packages are changed compared with latest
swrlapi.

Obviously, SWRL experiences a significant change. Only a few core built-ins
mentioned by w3c[3] were saved, others were removed.



/ public boolean isSymmetricProperty(List<BuiltInArgument> arguments) throws
BuiltInException
  {
    checkNumberOfArgumentsEqualTo(1, arguments.size());
    String propertyURI = getArgumentAsAPropertyURI(0, arguments);

    boolean result = false;
    try {
      result = SWRLOWLUtil.isOWLSymmetricProperty(getOWLModel(),
propertyURI, true);
    } catch (SWRLOWLUtilException e) {
      throw new BuiltInException(e.getMessage());
    } // try

    return result;
  } /








[1]
http://protege.stanford.edu/protege/3.4/docs/api/owl/edu/stanford/smi/protegex/owl/swrl/bridge/builtins/tbox/SWRLBuiltInLibraryImpl.html#isClassDescription(java.util.List)
<http://protege.stanford.edu/protege/3.4/docs/api/owl/edu/stanford/smi/protegex/owl/swrl/bridge/builtins/tbox/SWRLBuiltInLibraryImpl.html#isClassDescription(java.util.List)>  

[2] https://searchcode.com/codesearch/view/77747074/
<https://searchcode.com/codesearch/view/77747074/>  

[3] https://www.w3.org/Submission/SWRL/
<https://www.w3.org/Submission/SWRL/>  



--
View this message in context: http://protege-project.136.n4.nabble.com/Could-I-use-SWRL-rules-to-determine-whether-a-object-property-is-a-symmetric-property-tp4667824p4667837.html
Sent from the Protege User mailing list archive at Nabble.com.
_______________________________________________
protege-user mailing list
[hidden email]
https://mailman.stanford.edu/mailman/listinfo/protege-user

-- 
Lorenz Bühmann
AKSW group, University of Leipzig
Group: http://aksw.org - semantic web research center
_______________________________________________ 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
Loading...