What is NLP4J?

NLP4J is a Java Library for Natural Language Processing.
NLP4J provides NLP of English and Japanese Language, and framework for text-mining.

Java for English Language NLP

import nlp4j.Document;
import nlp4j.Keyword;
import nlp4j.impl.DefaultDocument;
import nlp4j.stanford.StanfordPosAnnotator;
public class StanfordPosAnnotatorExample0 {
    public static void main(String[] args) throws Exception {
        Document doc = new DefaultDocument();
        doc.putAttribute("text", "I eat sushi with chopsticks.");
        StanfordPosAnnotator ann = new StanfordPosAnnotator();
        ann.setProperty("target", "text");
        ann.annotate(doc); // do annotation
        for (Keyword kwd : doc.getKeywords()) {
            System.err.println(kwd);
        }
    }
}

Result

I [facet=word.PRP, str=I]
eat [facet=word.VBP, str=eat]
sushi [facet=word.NN, str=sushi]
with [facet=word.IN, str=with]
chopstick [facet=word.NNS, str=chopsticks]
. [facet=word.., str=.]

Maven

<!-- https://mvnrepository.com/artifact/org.nlp4j/nlp4j-stanford -->
<dependency>
    <groupId>org.nlp4j</groupId>
    <artifactId>nlp4j-core</artifactId>
    <version>[1.3.1.0,)</version>
</dependency>
<dependency>
    <groupId>org.nlp4j</groupId>
    <artifactId>nlp4j-stanford</artifactId>
    <version>[1.3.0.0,)</version>
</dependency>
<!-- https://mvnrepository.com/artifact/edu.stanford.nlp/stanford-corenlp -->
<dependency>
    <groupId>edu.stanford.nlp</groupId>
    <artifactId>stanford-corenlp</artifactId>
    <version>4.0.0</version>
    <scope>provided</scope>
</dependency>
<!-- https://mvnrepository.com/artifact/edu.stanford.nlp/stanford-corenlp -->
<dependency>
    <groupId>edu.stanford.nlp</groupId>
    <artifactId>stanford-corenlp</artifactId>
    <version>4.0.0</version>
    <classifier>models</classifier>
    <scope>provided</scope>
</dependency>

NLP4J Apps on Azure

NLP4J Apps

NLP4J GitHub

GitHub - oyahiroki/nlp4j: Natural Language Processing library for Java
Natural Language Processing library for Java. Contribute to oyahiroki/nlp4j development by creating an account on GitHub.

NLP4J Maven

Please Wait... | Cloudflare

NLP4J Qiita

NLP4J - Javaで自然言語処理 - Qiita
NLP4J はテキストマイニングや自然言語処理に必要な以下の機能を提供するJavaライブラリです。 データ収集機能 (クローラー Crawler) 自然言語処理呼び出し機能 (アノテーター Annotator) 形態素解析 構...

Recent Posts

Contact

Hiroki Oya 大矢裕己
2001-2018 IBM Japan Software Lab.
2018- Nissan Motor Co Ltd. Connected Car Service Dev
https://twitter.com/oyahiroki
https://www.linkedin.com/in/oyahiroki/
https://github.com/oyahiroki/nlp4j