From 72521c40c73c5a2a65470e4b2564b4ca159b94a5 Mon Sep 17 00:00:00 2001 From: queue Date: Wed, 27 May 2020 18:09:27 -0600 Subject: [PATCH] Fix weird offset error with word_delimiter_graph yet another es7-ism i guess --- es_mapping.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/es_mapping.yml b/es_mapping.yml index d1939d2..a46718e 100644 --- a/es_mapping.yml +++ b/es_mapping.yml @@ -10,7 +10,6 @@ settings: char_filter: - my_char_filter filter: - - standard - lowercase my_index_analyzer: type: custom @@ -66,9 +65,13 @@ settings: type: pattern_capture patterns: ["0*([0-9]*)"] word_delimit: - type: word_delimiter + type: word_delimiter_graph preserve_original: true split_on_numerics: false + # https://www.elastic.co/guide/en/elasticsearch/reference/current/analysis-word-delimiter-graph-tokenfilter.html#word-delimiter-graph-tokenfilter-configure-parms + # since we're using "trim" filters downstream, otherwise + # you get weird lucene errors about startOffset + adjust_offsets: false char_filter: my_char_filter: type: mapping