Keyword Extraction

Zia Keyword Extraction is a part of Text Analytics that processes textual content and extracts the highlights of the text. The extracted terms are grouped into two categories: Keywords and Keyphrases. These highlights deliver a concise summary of the text and provide an abstraction of the whole text.

The response contains an array of the key words, and another array of the key phrases that are extracted from 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 getKeywordExtraction(). The keywords and keyphrases are then fetched as individual lists.

Ensure the following packages are imported:

Copiedimport org.json.simple.JSONArray;
import com.zc.component.ml.ZCKeywordExtractionData;
import com.zc.component.ml.ZCML;
CopiedJSONArray 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

List<ZCKeywordExtractionData> listOfKeywordExtractionData = ZCML.getInstance().getKeywordExtraction(textArray); //Text is passed
		
ZCKeywordExtractionData  keywordExtractionData = listOfKeywordExtractionData.get(0);
		
List<String> keywordsList = keywordExtractionData.getKeywords(); //To fetch the keywords
List<String> keyphrasesList =  keywordExtractionData.getKeyphrases(); //To fetch the keyphrases