Nit wrapper for Stanford CoreNLP

Stanford CoreNLP provides a set of natural language analysis tools which can take raw text input and give the base forms of words, their parts of speech, whether they are names of companies, people, etc., normalize dates, times, and numeric quantities, and mark up the structure of sentences in terms of phrases and word dependencies, indicate which noun phrases refer to the same entities, indicate sentiment, etc. This wrapper needs the Stanford CoreNLP jars that run on Java 1.8+. See


~~~nitish var proc = new NLPProcessor("path/to/StanfordCoreNLP/jars") var doc = proc.process("String to analyze") for sentence in doc.sentences do for token in sentence.tokens do print "{token.lemma}: {token.pos}" end end ~~~


For ease of use, this wrapper introduce a Nit model to handle CoreNLP XML results.




NLP Processor

NitNLP binary

The `nitnlp` binary is given as an example of NitNLP client. It compares two strings and display ther cosine similarity value. Usage: ~~~raw nitnlp --cp "/path/to/jars" "sort" "Sorting array data" 0.577 ~~~


* Use JWrapper * Use options to choose CoreNLP analyzers * Analyze sentences dependencies * Analyze sentiment