Constructor WordDelimiterOptions
- Namespace
- MongoDB.EntityFrameworkCore.Metadata.Search
- Assembly
- MongoDB.EntityFrameworkCore.dll
WordDelimiterOptions(bool?, bool?, bool?, bool?, bool?, bool?, bool?, bool?, bool?, bool?, bool?)
Options for the MongoDB Search "wordDelimiterGraph" token filter, as used by AddWordDelimiterGraphFilter(WordDelimiterOptions?, IEnumerable<string>?).
public WordDelimiterOptions(bool? GenerateWordParts = null, bool? GenerateNumberParts = null, bool? ConcatenateWords = null, bool? ConcatenateNumbers = null, bool? ConcatenateAll = null, bool? PreserveOriginal = null, bool? SplitOnCaseChange = null, bool? SplitOnNumerics = null, bool? StemEnglishPossessive = null, bool? IgnoreKeywords = null, bool? IgnoreCaseForProtectedWords = null)
Parameters
GenerateWordPartsbool?If true, generate tokens for alphabetic subword parts split at delimiters and case changes (e.g.,
PowerShot→Power,Shot).GenerateNumberPartsbool?If true, generate tokens for numeric subword parts (e.g.,
500D→500,D).ConcatenateWordsbool?If true, add a token that is the concatenation of adjacent alphabetic subwords with delimiters removed (e.g.,
power_shot→powershotin addition to parts).ConcatenateNumbersbool?If true, add a token that is the concatenation of adjacent numeric subwords (e.g.,
500-20→50020in addition to parts).ConcatenateAllbool?If true, add a token that is the concatenation of all subwords (letters and numbers) with delimiters removed (e.g.,
PowerShot-500D→PowerShot500D).PreserveOriginalbool?If true, keep the input token as‑is in addition to any generated parts or concatenations. Useful to match both split and unsplit forms.
SplitOnCaseChangebool?If true, split tokens at case transitions (e.g.,
camelCase→camel,Case).SplitOnNumericsbool?If true, split tokens between alphabetic and numeric boundaries (e.g.,
500D→500,D).StemEnglishPossessivebool?If true, remove English possessive
'sfrom the end of words before further processing (e.g.,children's→children).IgnoreKeywordsbool?If true, do not modify tokens that have been marked as keywords by an upstream
keywordMarkerfilter.IgnoreCaseForProtectedWordsbool?If true, treat entries in the protected words list as case‑insensitive when matching. Has an effect only when protected words are configured on the filter.
Remarks
The wordDelimiterGraph token filter splits and/or concatenates tokens around case
changes, numeric boundaries, and non‑alphanumeric delimiters (such as underscores and hyphens).
These options control whether subword parts are generated, whether catenated (joined) forms are
added, whether to preserve the original token, and how to treat English possessives and protected
words. Use these flags to tailor tokenization of identifiers and compound words such as
PowerShot-500D, camelCase, or snake_case.
For details, see the Atlas Search documentation for the token filter:
https://www.mongodb.com/docs/atlas/atlas-search/analyzers/token-filters/#worddelimitergraph.