All Text Analytics

Text Analytics as a whole includes a combination of all three features specified in the previous sections: Sentiment Analysis, Named Entity Recognition, and Keyword Extraction. You can perform all three actions on a specific block of text, and obtain the tone of the text, the categorizations of the entities recognized from it, and key words and phrases that provide a gist of the text.

You can pass a block of text as the input of upto 1500 characters in a single request, as shown below. The text is passed to getTextAnalytics(). You can also pass optional keywords to perform Sentiment Analysis on the sentences containing only those keywords.

The response contains the results of each of the text analytics feature. Refer to each feature page for detailed information on their respective functionalities and responses.

Ensure the following packages are imported:

import org.json.simple.JSONArray; import; import; import; import; import; import;
JSONArray textArray = new JSONArray(); textArray.add("Zoho Corporation, is an Indian multinational technology company that makes web-based business tools. It is best known for Zoho Office Suite. The company was founded by Sridhar Vembu and Tony Thomas and has a presence in seven locations with its global headquarters in Chennai, India, and corporate headquarters in Pleasanton,California."); //Input text to be processed JSONArray keywords = new JSONArray(); keywords.add("Zoho"); //Optional keywords for Sentiment Analysis List listOfTextAnalyticsData = ZCML.getInstance().getTextAnalytics(textArray,keywords); //Text and keywords are passed ZCTextAnalyticsData textAnalyticsData = listOfTextAnalyticsData.get(0); ZCKeywordExtractionData keywordExtractionData = textAnalyticsData.getKeywordExtractionData(); //To perform Keyword Extraction on the text Z CNERData nerData = textAnalyticsData.getNERData(); //To perform NER on the text ZCSentimentAnalysisData sentimentAnalysisData = textAnalyticsData.getSentimentAnalysisData(); //To perform Sentiment Analysis on the text

Last Updated 2023-09-03 01:06:41 +0530 +0530



All Text Analytics - API