From 8b490b9b94511e85dd37ab655d5ccead71ba6a4e Mon Sep 17 00:00:00 2001 From: syuilo Date: Wed, 5 Sep 2018 16:48:59 +0900 Subject: [PATCH] #2607 --- src/db/elasticsearch.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/db/elasticsearch.ts b/src/db/elasticsearch.ts index 4acff40793..ee5769d1d4 100644 --- a/src/db/elasticsearch.ts +++ b/src/db/elasticsearch.ts @@ -4,6 +4,12 @@ import config from '../config'; const index = { settings: { analysis: { + normalizer: { + lowercase_normalizer: { + type: 'custom', + filter: ['lowercase'] + } + }, analyzer: { bigram: { tokenizer: 'bigram_tokenizer' @@ -24,7 +30,8 @@ const index = { text: { type: 'text', index: true, - analyzer: 'bigram' + analyzer: 'bigram', + normalizer: 'lowercase_normalizer' } } }