<commit_before>[[analysis-charfilters]]
== Character Filters

Character filters are used to preprocess the string of 
characters before it is passed to the <<analysis-tokenizers,tokenizer>>.
A character filter may be used to strip out HTML markup, , or to convert
`"&"` characters to the word `"and"`.    

Elasticsearch has built in characters filters which can be
used to build <<analysis-custom-analyzer,custom analyzers>>.

include::charfilters/mapping-charfilter.asciidoc[]

include::charfilters/htmlstrip-charfilter.asciidoc[]

include::charfilters/pattern-replace-charfilter.asciidoc[]<commit_msg>comma(,) was duplicated<commit_after>[[analysis-charfilters]]
== Character Filters

Character filters are used to preprocess the string of 
characters before it is passed to the <<analysis-tokenizers,tokenizer>>.
A character filter may be used to strip out HTML markup, or to convert
`"&"` characters to the word `"and"`.    

Elasticsearch has built in characters filters which can be
used to build <<analysis-custom-analyzer,custom analyzers>>.

include::charfilters/mapping-charfilter.asciidoc[]

include::charfilters/htmlstrip-charfilter.asciidoc[]

include::charfilters/pattern-replace-charfilter.asciidoc[]
{'fraction_non_alphanumeric': 0.09868421052631579, 'fraction_numerical': 0.0, 'mean_word_length': 6.075581395348837, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5553646', 'n_tokens_mistral': 337, 'n_tokens_neox': 340, 'n_words': 113}