}
// Use a HashSet to calculate the total vocabulary size
Set<String> vocabulary = new HashSet<String>();
// Read tuples from generate job
for(FileStatus fileStatus : fileSystem.globStatus(generatedModel)) {
TupleInputReader reader = new TupleInputReader(conf);
reader.initialize(fileStatus.getPath(), conf);
while(reader.nextKeyValueNoSync()) {
// Read Tuple
ITuple tuple = reader.getCurrentKey();
Integer count = (Integer) tuple.get("count");
Category category = (Category) tuple.get("category");
String word = tuple.get("word").toString();
vocabulary.add(word);
tokensPerCategory.put(category, MapUtils.getInteger(tokensPerCategory, category, 0) + count);