從semcor語料庫(http://www.cse.unt.edu/~rada/downloads.html),有些意義未映射到較高版本的wordnet。和神奇,映射可以在NLTK WordNet的API中找到這樣:NLTK wordnet接口中的第0個同義詞
>>> from nltk.corpus import wordnet as wn
# Emunerate the possible senses for the lemma 'delayed'
>>> wn.synsets('delayed')
[Synset('delay.v.01'), Synset('delay.v.02'), Synset('stay.v.06'), Synset('check.v.07'), Synset('delayed.s.01')]
>>> wn.synset('delay.v.01')
Synset('delay.v.01')
# Magically, there is a 0th sense of the word!!!
>>> wn.synset('delayed.a.0')
Synset('delayed.s.01')
我檢查代碼和API(http://nltk.googlecode.com/svn/trunk/doc/api/nltk.corpus.reader.wordnet.Synset-class.html,http://nltk.org/_modules/nltk/corpus/reader/wordnet.html),但我無法找到他們是如何做到的神奇作圖不應該不存在(例如,對於delayed.a.0
- >delayed.s.01
)。
有誰知道NLTK Wordnet API代碼的哪一部分做了神奇的映射嗎?