It seems you have java on your path so you don't need to worry about JAVA_HOME or the JAVA_CMD variable. You can change the last line of the .bat file to:
java -Xmx1024m -jar %OPENNLP_HOME%\lib\opennlp-tools-*.jar %* Note: I decreased the java heap size to 1024m, as the previous value of 4096m (4 Gb!) is way too large for my laptop! I don't know where you got your .model files from but I downloaded my .bin files from here: http://opennlp.sourceforge.net/models-1.5/ (This was a few months ago now but I assume they've not changed.) Steve. -- Steve Eynon ------------------------------- "If at first you don't succeed, so much for skydiving!" On 11 June 2011 23:20, Amal Elmah <amalalthougha...@hotmail.com> wrote: > > Hi , > > thanks alot Steve it works well when I write > java -jar lib\opennlp-tools-*.jar > > How can I solve JAVA_HOME problem? > I noticed that opennlp.bat file contains some variables that have no values > such as > JAVA_ACM > OPENNLP_HOME > should I set value to them ?? > > and I noticed that all the models I donloaded have the extention .model not > .bin ?? I there any difference and How can I download models with bin > extention > so I can use them as in the documentation, I follow the instructions in the > documentation because I am beginner and no nothing about using opennlp > toos > > Best, > Amal > >> From: steve.ey...@alienfactory.co.uk >> Date: Sat, 11 Jun 2011 21:51:54 +0800 >> Subject: Re: OPENNLP tools >> To: opennlp-users@incubator.apache.org >> >> Sounds like your JAVA_HOME environment variable is a bit screwy - try >> this from the same place: >> >> >java -jar lib\opennlp-tools-*.jar >> >> But given OpenNLP is primarily a Java API, I think you may struggle >> trying to use it purely as a command line tool. >> >> Steve. >> -- >> Steve Eynon >> ------------------------------- >> "If at first you don't succeed, >> so much for skydiving!" >> >> >> On 11 June 2011 21:19, Amal Elmah <amalalthougha...@hotmail.com> wrote: >> > >> > Hi, >> > >> > I tried to use Opennlp tools so I downloaded the >> > apache-opennlp-1.5.1-incubating-bin.zip from the following page >> > http://incubator.apache.org/opennlp/download.cgi >> > then I unzip this folder >> > I followed the instructions in the documentation >> > http://incubator.apache.org/opennlp/documentation/manual/opennlp.html to >> > try to make a tocknizer >> > so I wrote the following in the command line >> > >> > C:\Pipe\apache-opennlp-1.5.1-incubating-bin\apache-opennlp-1.5.1-incubating> >> > bin\opennlp.bat SimpleTokenizer >> > >> > bu I have got the following error! what does this error mean????? >> > >> > \Java\jdk1.6.0_25\bin\bin\java was unexpected at this time. >> > >> > thanks, >> > Amal >