Technically, the whole phrase vanilla ice cream is the object, with vanilla <- ice <- being subtree tokens of cream. Currently, Currently, match_either_lemma considers only the head token cream as the object, so it returns false when calling match_either_lemma(obj={"vanilla"}).
As an NLP user, I expect match_either_lemma to recognise tokens within the subtree of the phrase head.
Example: I want vanilla ice cream
Technically, the whole phrase
vanilla ice cream
is the object, withvanilla <- ice <-
being subtree tokens ofcream
. Currently, Currently,match_either_lemma
considers only the head tokencream
as the object, so it returns false when callingmatch_either_lemma(obj={"vanilla"})
.As an NLP user, I expect match_either_lemma to recognise tokens within the subtree of the phrase head.