Class WordCorrectionGenerator
- java.lang.Object
-
- org.predict4all.nlp.words.correction.WordCorrectionGenerator
-
public class WordCorrectionGenerator extends Object
Generate possible correction from a input text and tokens.
Correction are based on rule (CorrectionRule
) and generation is done using a thread pool.
Result correction could be unique word or double word (for example, the error might be a merged word)
-
-
Constructor Summary
Constructors Constructor Description WordCorrectionGenerator(WordDictionary wordDictionary, AbstractNGramDictionary<? extends AbstractNGramTrieNode<?>> staticNgramDictionary, PredictionParameter predictionParameter)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addCorrectionsFor(String prefixRaw, Map<BiIntegerKey,NextWord> words, Set<Integer> wordIdsToExclude)
void
dispose()
-
-
-
Constructor Detail
-
WordCorrectionGenerator
public WordCorrectionGenerator(WordDictionary wordDictionary, AbstractNGramDictionary<? extends AbstractNGramTrieNode<?>> staticNgramDictionary, PredictionParameter predictionParameter)
-
-