Hi Stardog Community,
I have having trouble reasoning with a OWL+SWRL ontology in Stardog.
Say we have the following hierarchy:
In the ontology, we have the following rule:
Fruit(?x) ^ Fruit(?y) ^ isFromSameFruitTreeAs(?y, ?x) ^ colorOf(?z, ?x) -> colorOf(?z, ?y)
This rule says that if two peices of fruit are from the same tree, then they are the same color (perhaps not true but let's say it is for this example).
Then say, for example, I have an two individuals of type Apple that are from the same tree. If apple ?x in red, then the rule should infer that apple ?y is red.
This works alright when I run it in Protege. However, when I move to Stardog this inference is not made (using the SL reasoner). However, the rule does work if I remove the part of the rule that says Fruit(?x) ^ Fruit(?y).
I may be missing something here. It seems that the class inference (Apple is a Fruit) not included in the rule inference.
I was wondering what the issue could be here? Am I doing something wrong or is this just how the SL reasoner works?