Lukket

Help with C# Wordnet Library

I need help getting the [url removed, login to view] library working for a project I'm working on.

Available via subversion here: [url removed, login to view]

Specifically, I'm trying to run "Lexicon Sample" ("\Samples\Contributed\Lexicon - Jeff Martin") to get guess a word's part-of-speech and get synonyms.

It's able to parse Wordnet 3 files and guess the part-of-speech; the problem is trying to lookup synonyms, and it seems to be a problem with the way it's reading the files.

Steps to re-create the problem:

0. Modify [url removed, login to view] of the Lexicon sample to point to a local copy of Wordnet 3 ([url removed, login to view])

1. "Lookup Part of Speech" for the word "Brilliant" -- this works; it finds 6 adjective senses

2. Now, "Lookup Synonyms"

-2.1 the first indication of a problem is from the [url removed, login to view] on line 125 in [url removed, login to view] of the [url removed, login to view] library:

"Error reading adj file! 2350714: 01 ruled 0 001 & 02337347 a 0000 | subject to a ruling authority; "the ruled mass" "

-2.2 an exception is thrown on line 160 of [url removed, login to view]:

"Input string was not in a correct format."

The error occurs in the Parse function, which presumably takes a line from the Wordnet file and tries to parse the pointers to other senses (I'm not very familiar with Wordnet - this is just a guess).

The code in question is:

155 void Parse(string s, PartOfSpeech fpos, string word)

156 {

157 int j;

158 StrTok st = new StrTok(s);

159 int off = [url removed, login to view]([url removed, login to view]());

160 fnum = [url removed, login to view]([url removed, login to view]());

the string that is being passed to "s" for the keyword "brilliant" is:

01 ruled 0 001 & 02337347 a 0000 | subject to a ruling authority; "the ruled mass"

This doesn't seem right... I'm not sure if the Wordnet format has changed, or there's a bug with reading the files.

I appreciate your help in getting this to work. Cheers

Færdigheder: C# Programmering, Natursprog

Se mere: wordnet library, help wordnet, run wordnet project, synonyms wordnet, library work wordnet, wordnet code, function synonyms wordnet, the string problem, the first programming language, string library in c, string library c, string j, programming with c language, programming with c++, programming with c, programming question in c, programming pointers, programming library, problem with error, pointers in c programming, pointers c programming, parse programming, natural programming language, Natural language programming, library programming

Om arbejdsgiveren:
( 0 bedømmelser ) United States

Projekt-ID: #4115340

5 freelancers are bidding on average $34 for this job

vano101

I have large experience with working with open source code, and I'm sure it's not a problem for me top find what does cause this error and how to fix it.

$30 USD på 1 dag
(92 bedømmelser)
5.2
ultrasonicsoft

Hi, I can help you with this problem.

$30 USD in 0 dage
(3 bedømmelser)
3.9
wrarvw

Hello. I'm a professional C# programmer and I have a lot of experience with debugging C# programs.

$50 USD in 2 dage
(6 bedømmelser)
3.1
sunsanych

Hi. May be I found problem. In the folder 'dict' are missing files. Exception occurs when reading the missing file in method [url removed, login to view](). If need urgent solution you can wrap all calls [url removed, login to view]( Mere

$30 USD på 1 dag
(0 bedømmelser)
0.0
vanpham

Hello, I've downloaded the project and I can't reproduce your bug. It run well on my PC.

$30 USD på 1 dag
(0 bedømmelser)
0.0