KeepTokenFilter Class

A token filter that only keeps tokens with text contained in a specified list of words. This token filter is implemented using Apache Lucene.

All required parameters must be populated in order to send to Azure.

Inheritance
azure.search.documents.indexes._generated.models._models_py3.TokenFilter
KeepTokenFilter

Constructor

KeepTokenFilter(*, name: str, keep_words: List[str], lower_case_keep_words: Optional[bool] = False, **kwargs)

Parameters

odata_type
str
Required

Required. Identifies the concrete type of the token filter.Constant filled by server.

name
str
Required

Required. The name of the token filter. It must only contain letters, digits, spaces, dashes or underscores, can only start and end with alphanumeric characters, and is limited to 128 characters.

keep_words
list[str]
Required

Required. The list of words to keep.

lower_case_keep_words
bool
Required

A value indicating whether to lower case all words first. Default is false.