Class TextFeatureExtractorImpl<T extends Output<T>>

java.lang.Object
org.tribuo.data.text.impl.TextFeatureExtractorImpl<T>
All Implemented Interfaces:
com.oracle.labs.mlrg.olcut.config.Configurable, com.oracle.labs.mlrg.olcut.provenance.Provenancable<com.oracle.labs.mlrg.olcut.provenance.ConfiguredObjectProvenance>, TextFeatureExtractor<T>

public class TextFeatureExtractorImpl<T extends Output<T>> extends Object implements TextFeatureExtractor<T>
An implementation of TextFeatureExtractor that takes a TextPipeline and generates ArrayExample.
  • Constructor Details

    • TextFeatureExtractorImpl

      public TextFeatureExtractorImpl(TextPipeline pipeline)
      Constructs a text feature extractor wrapping the supplied text pipeline.
      Parameters:
      pipeline - The text processing pipeline.
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • extract

      public Example<T> extract(T label, String data)
      Description copied from interface: TextFeatureExtractor
      Extracts an example from the supplied input text and output object.
      Specified by:
      extract in interface TextFeatureExtractor<T extends Output<T>>
      Parameters:
      label - The output object.
      data - The input text.
      Returns:
      An example
    • getProvenance

      public com.oracle.labs.mlrg.olcut.provenance.ConfiguredObjectProvenance getProvenance()
      Specified by:
      getProvenance in interface com.oracle.labs.mlrg.olcut.provenance.Provenancable<T extends Output<T>>