Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

consistency ignoring rule #30

Closed
shadialian opened this issue Jan 30, 2018 · 6 comments
Closed

consistency ignoring rule #30

shadialian opened this issue Jan 30, 2018 · 6 comments
Labels
help wanted Reporter need help to resolve his problem. invalid Developper said this isn't an issue.

Comments

@shadialian
Copy link

I am integrating openllet with jena and fuseki server and I have rules written in swrl. all the rule that is using the eval function is being ignored. is there anything I am missing. or another way to do calculations in swrl rules.
It' working fine in protege.

WARNING openllet.core.KnowledgeBaseImpl consistency Ignoring rule Rule(bnode(835f98b4-2720-4651-a0c8-ddde37746067) [HealthProfile(?hp), Hight(?hp,?h), Weight(?hp,?w), eval([?bmi, "w / ( h * h ) "^^string, ?w, ?h])] => [BMI(?hp,?bmi)]): No builtin for http://swrl.stanford.edu/ontologies/built-ins/3.4/swrlm.owl#eval

@Galigator
Copy link
Owner

Hello, I don't know this "eval" builtin function.
It doesn't look standard :

https://www.w3.org/Submission/SWRL/#8
http://dior.ics.muni.cz/~makub/owl/#swrlpredicates

Where does it come from ?

You can find some example of swrl with openllet here :

with standards builtin :
https://github.com/Galigator/openllet/blob/integration/module-owlapi/src/test/java/openllet/pellet/owlapi/test/TestBasic.java#L463
https://github.com/Galigator/openllet/blob/integration/module-owlapi/src/test/java/openllet/pellet/owlapi/test/TestBasic.java#L506

with user define builtin :
https://github.com/Galigator/openllet/blob/integration/module-owlapi/src/test/java/openllet/pellet/owlapi/test/TestBasic.java#L583

You can also take a look here for a complete list of already implemented builtins.
https://github.com/Galigator/openllet/blob/integration/tests/src/test/java/openllet/test/rules/SWRLBuiltIns.java (but there is no 'eval' function to be implemented).
Files in the same directory may enlighten you.

Also be careful with Jena, it is only 'OWL1', you may have surprises.

@Galigator
Copy link
Owner

My bad, you are using : https://github.com/protegeproject/swrlapi/wiki/SQWRL not SWRL.
SQWRL isn't support by Openllet. Maybe we could implement a bridge to SQWRL using the user define SWRL in Openllet. Also It would kill the the 'explenation' feature, that allow user to understand what's going on when inconsistency appear.

@shadialian
Copy link
Author

no, I am using swrl to define the rules.
this is the link to the builtins https://github.com/protegeproject/swrlapi/wiki/MathematicalBuiltInLibrary

@Galigator Galigator added the invalid Developper said this isn't an issue. label Jan 30, 2018
@Galigator
Copy link
Owner

swrlm:eval(?r, "(57 * x) / y)", ?x, ?y)" is an SQWRL construct not an SWRL construct.

By reading https://github.com/protegeproject/swrlapi/wiki/SQWRL, I understand that binding SQWRL to Openllet could be an interesting 3 years phd research project.

@Galigator Galigator added the help wanted Reporter need help to resolve his problem. label Jan 30, 2018
@shadialian
Copy link
Author

Thanks for the clarification. is there any guides for creating custom built-ins for openllet. And for the Jena that it only support OWL1. do you have any alternatives that I can use? I am currently using the Fuseki server to query my ontology over HTTP using sparql from mobile apps.

@Galigator
Copy link
Owner

There is no guides for creating custom built-ins for openllet, but there is one example :
https://github.com/Galigator/openllet/blob/integration/module-owlapi/src/test/java/openllet/pellet/owlapi/test/TestBasic.java#L744

A replacement for Jena, could be the OWL-API, but it doesn't come with fuseki like tool, instead it use RIO/rdf4j like tools.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Reporter need help to resolve his problem. invalid Developper said this isn't an issue.
Projects
None yet
Development

No branches or pull requests

2 participants