Class StopWords

java.lang.Object
org.ek9lang.assist.StopWords

public final class StopWords extends Object
Stop word set and synonym group map for Q&A matching. Stop words are removed during tokenization as they carry no matching value. Synonym groups map related terms to a canonical form for better matching.
  • Method Details

    • tokenize

      public static Set<String> tokenize(String input)
      Tokenize input text for matching: lowercase, split, strip punctuation, remove stop words.
    • resolveSynonym

      public static String resolveSynonym(String word)
      Map a word to its canonical synonym form. Returns the original word if no synonym group contains it.
    • isStopWord

      public static boolean isStopWord(String word)
      Check if a word is a stop word.