File tree Expand file tree Collapse file tree 1 file changed +13
-10
lines changed
docs/reference/analysis/analyzers Expand file tree Collapse file tree 1 file changed +13
-10
lines changed Original file line number Diff line number Diff line change @@ -162,26 +162,26 @@ PUT my_index
162162 "settings": {
163163 "analysis": {
164164 "analyzer": {
165- "my_custom_analyzer": {
165+ "my_custom_analyzer": { <1>
166166 "type": "custom",
167167 "char_filter": [
168- "emoticons" <1>
168+ "emoticons"
169169 ],
170- "tokenizer": "punctuation", <1>
170+ "tokenizer": "punctuation",
171171 "filter": [
172172 "lowercase",
173- "english_stop" <1>
173+ "english_stop"
174174 ]
175175 }
176176 },
177177 "tokenizer": {
178- "punctuation": { <1 >
178+ "punctuation": { <2 >
179179 "type": "pattern",
180180 "pattern": "[ .,!?]"
181181 }
182182 },
183183 "char_filter": {
184- "emoticons": { <1 >
184+ "emoticons": { <3 >
185185 "type": "mapping",
186186 "mappings": [
187187 ":) => _happy_",
@@ -190,7 +190,7 @@ PUT my_index
190190 }
191191 },
192192 "filter": {
193- "english_stop": { <1 >
193+ "english_stop": { <4 >
194194 "type": "stop",
195195 "stopwords": "_english_"
196196 }
@@ -207,9 +207,12 @@ POST my_index/_analyze
207207--------------------------------------------------
208208// CONSOLE
209209
210- <1> The `emoticons` character filter, `punctuation` tokenizer and
211- `english_stop` token filter are custom implementations which are defined
212- in the same index settings.
210+ <1> Assigns the index a default custom analyzer, `my_custom_analyzer`. This
211+ analyzer uses a custom tokenizer, character filter, and token filter that
212+ are defined later in the request.
213+ <2> Defines the custom `punctuation` tokenizer.
214+ <3> Defines the custom `emoticons` character filter.
215+ <4> Defines the custom `english_stop` token filter.
213216
214217/////////////////////
215218
You can’t perform that action at this time.
0 commit comments