diff --git a/natural-language-understanding/README.md b/natural-language-understanding/README.md new file mode 100644 index 00000000000..74977bac90d --- /dev/null +++ b/natural-language-understanding/README.md @@ -0,0 +1,33 @@ +# Natural Language Understanding + +## Installation + +##### Maven +```xml + + com.ibm.watson.developer_cloud + natural-language-understanding + 3.7.1 + +``` + +##### Gradle +```gradle +'com.ibm.watson.developer_cloud:natural-language-understanding:3.7.1' +``` + +## Usage +Use [Natural Language Understanding](http://www.ibm.com/watson/developercloud/doc/natural-language-understanding/index.html) +to analyze various features of text content at scale. Provide text, raw HTML, or a public URL, and IBM Watson Natural +Language Understanding will give you results for the features you request. The service cleans HTML content before +analysis by default, so the results can ignore most advertisements and other unwanted content. + +```java +NaturalLanguageUnderstanding service = new NaturalLanguageUnderstanding(); +service.setUsernameAndPassword("", ""); + +EntitiesOptions entities = new EntitiesOptions.Builder().sentiment(true).limit(1).build(); +Features features = new Features.Builder().entities(entities).build(); +AnalyzeOptions parameters = new AnalyzeOptions.Builder().url("www.cnn.com").features(features).build(); +AnalysisResults results = service.analyze(parameters).execute(); +```