forked from stanfordnlp/CoreNLP
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add boolean to indicate presence of coref info
- Loading branch information
Showing
11 changed files
with
102 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
java -mx1500m -cp "stanford-ner.jar;lib/*" edu.stanford.nlp.ie.crf.NERGUI | ||
java -mx1500m -cp "stanford-ner.jar;lib/*" edu.stanford.nlp.ie.crf.NERGUI |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
java -mx1000m -cp stanford-ner.jar;lib/* edu.stanford.nlp.ie.crf.CRFClassifier -loadClassifier classifiers\english.all.3class.distsim.crf.ser.gz -textFile %1 | ||
java -mx1000m -cp stanford-ner.jar;lib/* edu.stanford.nlp.ie.crf.CRFClassifier -loadClassifier classifiers\english.all.3class.distsim.crf.ser.gz -textFile %1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,84 +1,84 @@ | ||
@echo off | ||
|
||
:: Usage: "segment ctb|pk filename encoding kBest" | ||
:: encoding can be UTF-8 or GB18030 or GB | ||
|
||
if "%4"=="" ( | ||
echo Too few arguments | ||
call :usage %~nx0 | ||
goto :EOF | ||
) | ||
if not "%6"=="" ( | ||
echo Too many arguments | ||
call :usage %~nx0 | ||
goto :EOF | ||
) | ||
|
||
set ARGS=-keepAllWhitespaces false | ||
if not "%5"=="" ( | ||
if not "%1"=="-k" ( | ||
echo First argument must be "-k" | ||
call :usage %~nx0 | ||
goto :EOF | ||
) | ||
set ARGS=-keepAllWhitespaces true | ||
set lang=%~2 | ||
set file=%~3 | ||
set enc=%~4 | ||
set kBest=%~5 | ||
) else ( | ||
if not "%4"=="" ( | ||
set lang=%~1 | ||
set file=%~2 | ||
set enc=%~3 | ||
set kBest=%~4 | ||
) else ( | ||
echo Unknown argument error | ||
call :usage %~nx0 | ||
goto :EOF | ||
) | ||
) | ||
|
||
if "%lang%"=="ctb" ( | ||
echo CTB: Chinese Treebank segmentation >&2 | ||
) else ( | ||
if "%lang%"=="pku" ( | ||
echo PKU: Beijing University segmentation >&2 | ||
) else ( | ||
echo Language argument should be either ctb or pku. Abort | ||
goto :EOF | ||
) | ||
) | ||
|
||
echo File: "%file%" >&2 | ||
echo Encoding: "%enc%" >&2 | ||
echo kBest: "%kBest%" >&2 | ||
echo ------------------------------- >&2 | ||
|
||
set BASEDIR=%~dp0 | ||
set DATADIR=%BASEDIR%data | ||
:: set LEXDIR=%DATADIR%lexicons | ||
set JAVACMD=java -mx1024m -cp "%BASEDIR%*;" edu.stanford.nlp.ie.crf.CRFClassifier -sighanCorporaDict "%DATADIR%" -textFile "%file%" -inputEncoding %enc% -sighanPostProcessing true %ARGS% | ||
set DICTS=%DATADIR%\dict-chris6.ser.gz | ||
set KBESTCMD= | ||
if not %kBest%==0 set kBestCmd=-kBest %kBest% | ||
|
||
if "%lang%"=="ctb" ( | ||
%JAVACMD% -loadClassifier "%DATADIR%\%lang%.gz" -serDictionary "%DICTS%" "%KBESTCMD%" | ||
) | ||
if "%lang%"=="pku" ( | ||
%JAVACMD% -loadClassifier "%DATADIR%\%lang%.gz" -serDictionary "%DICTS%" "%KBESTCMD%" | ||
) | ||
|
||
goto :EOF | ||
|
||
:usage | ||
echo Usage: "%1 [-k] ctb|pku filename encoding kBest" >&2 | ||
echo -k : keep whitespaces >&2 | ||
echo ctb : use Chinese Treebank segmentation >&2 | ||
echo pku : Beijing University segmentation >&2 | ||
echo kBest: print kBest best segmenations; 0 means kBest mode is off. >&2 | ||
echo. >&2 | ||
echo Example: %1 ctb test.simp.utf8 UTF-8 0 >&2 | ||
echo Example: %1 pku test.simp.utf8 UTF-8 0 >&2 | ||
goto :EOF | ||
@echo off | ||
|
||
:: Usage: "segment ctb|pk filename encoding kBest" | ||
:: encoding can be UTF-8 or GB18030 or GB | ||
|
||
if "%4"=="" ( | ||
echo Too few arguments | ||
call :usage %~nx0 | ||
goto :EOF | ||
) | ||
if not "%6"=="" ( | ||
echo Too many arguments | ||
call :usage %~nx0 | ||
goto :EOF | ||
) | ||
|
||
set ARGS=-keepAllWhitespaces false | ||
if not "%5"=="" ( | ||
if not "%1"=="-k" ( | ||
echo First argument must be "-k" | ||
call :usage %~nx0 | ||
goto :EOF | ||
) | ||
set ARGS=-keepAllWhitespaces true | ||
set lang=%~2 | ||
set file=%~3 | ||
set enc=%~4 | ||
set kBest=%~5 | ||
) else ( | ||
if not "%4"=="" ( | ||
set lang=%~1 | ||
set file=%~2 | ||
set enc=%~3 | ||
set kBest=%~4 | ||
) else ( | ||
echo Unknown argument error | ||
call :usage %~nx0 | ||
goto :EOF | ||
) | ||
) | ||
|
||
if "%lang%"=="ctb" ( | ||
echo CTB: Chinese Treebank segmentation >&2 | ||
) else ( | ||
if "%lang%"=="pku" ( | ||
echo PKU: Beijing University segmentation >&2 | ||
) else ( | ||
echo Language argument should be either ctb or pku. Abort | ||
goto :EOF | ||
) | ||
) | ||
|
||
echo File: "%file%" >&2 | ||
echo Encoding: "%enc%" >&2 | ||
echo kBest: "%kBest%" >&2 | ||
echo ------------------------------- >&2 | ||
|
||
set BASEDIR=%~dp0 | ||
set DATADIR=%BASEDIR%data | ||
:: set LEXDIR=%DATADIR%lexicons | ||
set JAVACMD=java -mx1024m -cp "%BASEDIR%*;" edu.stanford.nlp.ie.crf.CRFClassifier -sighanCorporaDict "%DATADIR%" -textFile "%file%" -inputEncoding %enc% -sighanPostProcessing true %ARGS% | ||
set DICTS=%DATADIR%\dict-chris6.ser.gz | ||
set KBESTCMD= | ||
if not %kBest%==0 set kBestCmd=-kBest %kBest% | ||
|
||
if "%lang%"=="ctb" ( | ||
%JAVACMD% -loadClassifier "%DATADIR%\%lang%.gz" -serDictionary "%DICTS%" "%KBESTCMD%" | ||
) | ||
if "%lang%"=="pku" ( | ||
%JAVACMD% -loadClassifier "%DATADIR%\%lang%.gz" -serDictionary "%DICTS%" "%KBESTCMD%" | ||
) | ||
|
||
goto :EOF | ||
|
||
:usage | ||
echo Usage: "%1 [-k] ctb|pku filename encoding kBest" >&2 | ||
echo -k : keep whitespaces >&2 | ||
echo ctb : use Chinese Treebank segmentation >&2 | ||
echo pku : Beijing University segmentation >&2 | ||
echo kBest: print kBest best segmenations; 0 means kBest mode is off. >&2 | ||
echo. >&2 | ||
echo Example: %1 ctb test.simp.utf8 UTF-8 0 >&2 | ||
echo Example: %1 pku test.simp.utf8 UTF-8 0 >&2 | ||
goto :EOF |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
:: runs the parser GUI | ||
:: usage lexparser-gui [parserDataFilename [textFileName]] | ||
java -mx800m -cp "*" edu.stanford.nlp.parser.ui.Parser | ||
:: runs the parser GUI | ||
:: usage lexparser-gui [parserDataFilename [textFileName]] | ||
java -mx800m -cp "*" edu.stanford.nlp.parser.ui.Parser |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
@echo off | ||
:: Runs the English PCFG parser on one or more files, printing trees only | ||
:: usage: lexparser fileToparse | ||
java -mx150m -cp "*;" edu.stanford.nlp.parser.lexparser.LexicalizedParser -outputFormat "penn,typedDependencies" edu/stanford/nlp/models/lexparser/englishPCFG.ser.gz %1 | ||
@echo off | ||
:: Runs the English PCFG parser on one or more files, printing trees only | ||
:: usage: lexparser fileToparse | ||
java -mx150m -cp "*;" edu.stanford.nlp.parser.lexparser.LexicalizedParser -outputFormat "penn,typedDependencies" edu/stanford/nlp/models/lexparser/englishPCFG.ser.gz %1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters