Dear Sir/Madam,
I am a research scholar and is trying to use the opennlp tool but is not
able to use with net-beans.
The tool seems to be complicated as no proper tutorials are provided. I
major problem is that I have downloaded a apache-opennlp-1.5.3-bin folder
which contains bin, jars,lib etc. I even set their path in environment
variables but still when I wish to use SentenceModel class it is showing
that it is not present.
The code is copied here.
package sp;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
/**
*
* @author shilpa
*/
public class Sp {
/**
* @param args the command line arguments
*/
public static void main(String[] args) throws FileNotFoundException {
// TODO code application logic here
InputStream modelIn ;
modelIn = new FileInputStream("en-token.bin");
try {
SentenceModel model = new SentenceModel(modelIn);
}
finally {
if (modelIn != null) {
try {
modelIn.close();
}
catch (IOException e) {
}
}
}
}
}
Kindly help.
--
Regards
Shilpa Pandey
PhD. ICT.
**
Ability may get you to the top, but it takes character to keep you there.