Research Article
Big Data Aspect-Based Opinion Mining Using the SLDA and HME-LDA Models
Algorithm 4. The process of automatically labelling data.
1: fort in Topics do //Process each seed word | 2: wordList = getWrodListFromCorpus(t) //Find the location where t appears from the corpus and get the corresponding word order | 3: wordCluster = getWordCluster(t) //Get all the words of the category t from the clustering results | 4: trainSet = new Set //Used to save labelled training samples | 5: for wOrder in wordList do | 6: for w in wordCluster do | 7: replaceWord(wOrder, t, w) //Replace the word t in the word order with w | 8: trainSet.add(wOrder, t.Type) //Add the label to which wOrder and t belong to the training set | 9: end for | 10: end for | 11: end for |
|
Algorithm 4. The process of automatically labelling data. |