You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In #13 (comment), @lajus said that areEquivalent checks subsumption, but it doesn't seem to be the case.
I'm reporting this behavior because I am not sure if its a bug, an intended behavior, or if I'm using it wrong. I guess that AMIE actually implements a specific version of "subsumption". For example, if it returned true for areEquivalent(3., 4.), the instantiated rule would be discarded.
Regards,
Antonio.
The text was updated successfully, but these errors were encountered:
I realized later that my statement in #13 was wrong as indeed I did not consider instantiations (just (bijective) variable renaming). There are also other edge cases to consider as the mapping is not required to be injective in the subsumption case (two variables may be mapped to the same variable).
It is in my Todo list with a very low priority as Rule.unify does the job for now (except for instantiations).
Thanks for the clarification. It makes total sense for the AMIE use case.
I agree with the low priority. I found this behavior when trying to check subsumption with areEquivalent. Nonetheless, I managed to fulfill my requirements by combining it with some pre-processing (I also didn't need full subsumption).
And "fails" for the reasons we discussed before. Besides depending on EquivalenceChecker, the check for Rule.areEquivalent does not bind variables to constants.
Hi,
Consider the rules:
?a equals ?b => ?a equals ?b
?a equals ?b => ?a equals B
?a equals ?b => ?a equals ?b
?a equals B => ?a equals ?b
As I understand, 1. unifies with 2., and 3. unifies with 4.
Nonetheless,
QueryEquivalenceChecker3.unify
/areEquivalent
returnsfalse
in both cases.This makes sense, since
unify
returns false when trying to unify a variable with a constant:https://github.com/lajus/amie/blob/40ebfa61e4e8bbf488e5fb1fc93b69ba791a8cab/rules/src/main/java/amie/rules/QueryEquivalenceChecker3.java#L30-L31.
In #13 (comment), @lajus said that
areEquivalent
checks subsumption, but it doesn't seem to be the case.I'm reporting this behavior because I am not sure if its a bug, an intended behavior, or if I'm using it wrong. I guess that AMIE actually implements a specific version of "subsumption". For example, if it returned true for
areEquivalent(3., 4.)
, the instantiated rule would be discarded.Regards,
Antonio.
The text was updated successfully, but these errors were encountered: