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
WordNet: Synsets' relations are absent from their corresponding lemmas #1970
Comments
The docstring for the Lemma class still claims that lemmas can directly return the relations defined for their synset. However, this is not true in practice, and such calls only return an empty list. It is true that anything that holds for a synset also holds for the lemmas included in that synset, so a user is free to interpret the synset relations as also holding for lemmas. However, since this can be achieved by simply obtaining the synset of the input lemma, it would be an unnecessary extension, which a generic WordNet interface does not need to include. In the WordNet database, synset relations are not defined at the lemma level, and there would not be any practical advantage in blurring the distinction between synset and lemma relations. So, in my opinion, the current practice is the most correct one. Then, the docstring of the Lemma class should probably be edited, to reflect that synset relations are not directly available at the lemma level, but need an intermediate call to synset(). |
On the other hand, most people probably think of hypernymy as a relation between words, rather than synsets. WordNet could be easier to use, and more widely accepted, if less knowledge of its peculiarities was required. So today I'm leaning more toward @marcevrard's viewpoint, and think that it could be advantageous to make synset relations directly accessible from the lemmas. |
Sorry for not responding much earlier. I think the logic here is for programmers to be clear about the difference between lemmas and synsets. Lemmas are forms. Synsets are concepts. I would prefer us to fix the documentation. |
Anyway, just editing the docstring would not be sufficient for fixing this issue. Currently, all the relations are defined at the level of the WordnetObject class, so the Lemma class inherits definitions for the hypernyms, hyponyms, etc..., and always returns an empty list for each call of these functions, as marcevrard notes.
On the other, according to this Wikipedia page , everybody else considers hyponymy to be a relation between words or terms:
So we cannot expect that programmers would want to learn a too strict interpretation of this distinction between synset and lemma relationships. Furthermore, we need to adress the special case of the hybrid relations, which have both synset and lemma occurences in WordNet, but are not yet properly supported by NLTK's wordnet.py module. |
In WordNet, it seems to me that the relations relevant for a given synset should be relevant for its corresponding lemmas as well. In the
nltk
implementation, all semantic relations implemented as methods for synsets (e.g.,hypernyms()
) are indeed also available for lemmas. Though for example, the lemmatrick.n.01.trick
hypernyms
method does not return anything, while its synset's does.Using the lemma method:
Using the the synset method instead:
Expected behavior of the lemma method:
Versions:
The text was updated successfully, but these errors were encountered: