EmptyFilter

class squirro.lib.nlp.steps.filters.EmptyFilter(config)

Bases: squirro.lib.nlp.steps.filters.Filter

Filters out empty fields

Parameters
  • type (str) – empty

  • field (str, None) – Field to filter

  • fields (list, None) – Fields to filter

  • replacement_value (object, None) – Value with which to replace an empty field

  • skip (bool, True) – Whether or not to skip a doc with an empty field

Methods Summary

process_doc(doc)

Process a document

Methods Documentation

process_doc(doc)

Process a document

Parameters

doc (Document) – Document

Returns

Processed document

Return type

Document