how to use WordNet in C#?

1k Views Asked by At

I want to find out synonyms of a specific word Like "help". The synonyms of help are "aid", "assist" or "assistance" etc.

I have downloaded the Wordnet library and used this in Visual Studio.

  1. Create new project
  2. Download library of Wordnet using Manage NuGet Packages.
  3. Work with this code:

    WordNetEngine wne = new WordNetEngine();
    PartOfSpeech pos = new PartOfSpeech();
    SynSet ss = new SynSet(pos, 0, wne);
    Console.WriteLine("words form wordnet" + ss.Words);
    

But this is not working.

Please can anyone help me in this regard with code example in C#?

1

There are 1 best solutions below

0
On

I do not know if you are still interested in this question, but these two Nuget Packages will help you:

https://developer.syn.co.in/tutorial/wordnet/tutorial.html

https://github.com/curiosity-ai/catalyst

In addition, please review the WordNet site for a complete guide about using the lexical database.