Lucene.Net  3.0.3
Lucene.Net is a port of the Lucene search engine library, written in C# and targeted at .NET runtime users.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Properties Pages
Static Public Member Functions | Public Attributes | List of all members
WorldNet.Net.Syns2Index Class Reference

Convert the prolog file wn_s.pl from the WordNet prolog download into a Lucene index suitable for looking up synonyms and performing query expansion (SynExpand.Expand). More...

Static Public Member Functions

static void Main (System.String[] args)
 Takes arg of prolog file name and index directory.
 

Public Attributes

const System.String F_SYN = "syn"
 
 
const System.String F_WORD = "word"
 
 

Detailed Description

Convert the prolog file wn_s.pl from the WordNet prolog download into a Lucene index suitable for looking up synonyms and performing query expansion (SynExpand.Expand).

This has been tested with WordNet 2.0.

The index has fields named "word" (F_WORD) and "syn" (F_SYN).

The source word (such as 'big') can be looked up in the "word" field, and if present there will be fields named "syn" for every synonym. What's tricky here is that there could be multiple fields with the same name, in the general case for words that have multiple synonyms. That's not a problem with Lucene, you just use Document.GetValues

While the WordNet file distinguishes groups of synonyms with related meanings we don't do that here.

This can take 4 minutes to execute and build an index on a "fast" system and the index takes up almost 3 MB.

See Also
http://www.cogsci.princeton.edu/~wn/
See Also
http://www.cogsci.princeton.edu/~wn/man/prologdb.5WN.html
See Also
http://www.hostmon.com/rfc/advanced.jsp

Definition at line 57 of file Syns2Index.cs.

Member Function Documentation

static void WorldNet.Net.Syns2Index.Main ( System.String[]  args)
static

Takes arg of prolog file name and index directory.

Definition at line 78 of file Syns2Index.cs.

Member Data Documentation

const System.String WorldNet.Net.Syns2Index.F_SYN = "syn"

Definition at line 66 of file Syns2Index.cs.

const System.String WorldNet.Net.Syns2Index.F_WORD = "word"

Definition at line 69 of file Syns2Index.cs.


The documentation for this class was generated from the following file: