Class LabelFilterProcessor

java.lang.Object
org.carrot2.attrs.AttrComposite
org.carrot2.text.preprocessing.LabelFilterProcessor
All Implemented Interfaces:
AcceptingVisitor

public class LabelFilterProcessor extends AttrComposite
Applies basic filtering to words and phrases to produce candidates for cluster labels. Filtering is applied to PreprocessingContext.AllWords and PreprocessingContext.AllPhrases, the results are saved to PreprocessingContext.AllLabels. Currently, the following filters are applied:
  1. StopWordLabelFilter
  2. CompleteLabelFilter
This class saves the following results to the PreprocessingContext:

This class requires that InputTokenizer, CaseNormalizer, StopListMarker and PhraseExtractor be invoked first.

  • Field Details

    • queryLabelFilter

      public QueryLabelFilter queryLabelFilter
      Query word label filter for this processor.
    • stopWordLabelFilter

      public StopWordLabelFilter stopWordLabelFilter
      Stop word label filter for this processor.
    • stopLabelFilter

      public StopLabelFilter stopLabelFilter
      Stop label filter.
    • numericLabelFilter

      public NumericLabelFilter numericLabelFilter
      Numeric label filter for this processor.
    • completeLabelFilter

      public CompleteLabelFilter completeLabelFilter
      Truncated phrase filter for this processor.
    • minLengthLabelFilter

      public MinLengthLabelFilter minLengthLabelFilter
      Min length label filter.
    • genitiveLabelFilter

      public GenitiveLabelFilter genitiveLabelFilter
      Genitive length label filter.
  • Constructor Details

    • LabelFilterProcessor

      public LabelFilterProcessor()
  • Method Details

    • process

      public void process(PreprocessingContext context)
      Processes all filters declared as fields of this class.