nlp :: NLPServer :: defaultinit
# Stanford web server
#
# Runs the server on `port`.
#
# For more details about the stanford NLP server see
# https://stanfordnlp.github.io/CoreNLP/corenlp-server.html
class NLPServer
super Thread
# Stanford jar classpath
#
# Classpath to give to Java when loading the StanfordNLP jars.
var java_cp: String
# Port the Java server will listen on
var port: Int
redef fun main do
sys.system "java -mx4g -cp \"{java_cp}\" edu.stanford.nlp.pipeline.StanfordCoreNLPServer -port {port.to_s} -timeout 15000"
return null
end
end
lib/nlp/stanford.nit:301,1--322,3