FAQ Database Discussion Community


How to find the Lexical Category of a word in wordnet using NLTK(python)

python,nltk,wordnet
The wordnet demo as shown here displays the lexical information of a file in its search result. for example the word motion has many lexical categories( as it has many "senses" ) one of them being "verb.motion".I have seen the other questions but they do not explain as to how...

Get the word from a WordNet synset

python,python-3.x,nltk,wordnet
Given a synset like this: Synset("pascal_celery.n.01") I want to get the word(s) it represents: "pascal celery" Currently, I'm doing this: synset.name().split(".")[0] but this doesn't convert underscores into spaces. Is there an inbuilt way of doing this?...

using Wordnet with standford nlp

java,stanford-nlp,wordnet
I'm trying to get WordnetSynAnnotation of a token, it always returns null. I'm not sure what I'm missing, is there an annotator for WordnetSynAnnotation here is my full code http://pastebin.com/x3kjU04C...

How create a database of all the english language words [closed]

mysql,database,mysqli,wordnet
I have asked a similar question before. I was asked to use wordnet. I have downloaded the wordnet database file. But how there are a lot of files. I don't know what to do with these file. And there aren't any instructions also. I just want to create a table...

Implement a semantic web search engine using Arabic wordnet

web-applications,arabic,wordnet
I want to develop a web application that will use the current AWN, and provide the user to obtain semantic results. What I require are the things that I need to know before going into implementation of the system. My purpose is to do semantic search in the Holy Quran....

How to tag monosemous words

java,wordnet,jaws-wordnet
i am using JAWS-Java API for wordnet searching.i have been searching alot but unable to find how to count the number of senses the given word can have.Is there any function for it? And after finding how the monosemous words can be tagged.

wordnet lemmatizer in NLTK is not working for adverbs [duplicate]

python,nlp,nltk,wordnet
This question already has an answer here: Getting adjective from an adverb in nltk or other NLP library 1 answer from nltk.stem import WordNetLemmatizer x = WordNetLemmatizer() x.lemmatize("angrily", pos='r') Out[41]: 'angrily' Here is reference documnetation for pos tags in nltk wordnet, http://www.nltk.org/_modules/nltk/corpus/reader/wordnet.html I may be missing some basic things....

Extrapolate Sentence Similarity Given Word Similarities

wordnet,cosine-similarity,word2vec,sentence-similarity
Assuming that I have a word similarity score for each pair of words in two sentences, what is a decent approach to determining the overall sentence similarity from those scores? The word scores are calculated using cosine similarity from vectors representing each word. Now that I have individual word scores,...

how to set environment variable java unix .getenv(NOT_WORKING)

java,jar,environment-variables,wordnet,jwi
printenv WNHOME echo $WNHOME both give me the correct answer but the java program does not. I'm trying to execute the example program featured in the JWI (the MIT Java Wordnet Interface), the first one featured in the 'User's Manual', as expressed in this question. However, when running the code...

Get noun from verb Wordnet

python,nlp,wordnet
I'm trying to get the noun from a verb with Wordnet in python. I want to be able to get : from the verb 'created' the noun 'creator', 'funded' => 'funder' Verb X => Noun Y Y is referring to a person I've been able to do it the other...

How to iterate through the synset list generated from wordnet using python 3.4.2

python-3.x,nlp,wordnet,sentiment-analysis
I am using wordnet to find the synonyms for a particular word as shown below synonyms = wn.synsets('good','a') where wn is wordnet. This returns a list of synsets like Synset('good.a.01') Synset('full.s.06') Synset('good.a.03') Synset('estimable.s.02') Synset('beneficial.s.01') etc... How to iterate through each synset and get the name and the pos tag of...

How compare wordnet Synsets with another word?

python,nltk,wordnet
I need to check if some word its sysnset of another words.. for example : cat and dog .. first i need to find synsets of cat by this code: list= wn.synsets('cat') then the list of synsets are returned: [Synset('cat.n.01'), Synset('guy.n.01'), Synset('cat.n.03'), Synset('kat.n.01'), Synset('cat-o'-nine-tails.n.01'), Synset('caterpillar.n.02'), Synset('big_cat.n.01'), Synset('computerized_tomography.n.01'), Synset('cat.v.01'), Synset('vomit.v.01') So,...

Logical flaw: if List is null return input else print function output

java,null,wordnet,stemming,data-processing
In my code I call this method, as a preprocessing step to 'stem' words: public void getStem(String word) { WordnetStemmer stem = new WordnetStemmer( dict ); List<String> stemmed_words = stem.findStems(word, POS.VERB); System.out.println( stemmed_words.get(0) ); } Usually everything is good if it gets a normal word (I'm using the Java Wordnet...