Advertisement
nainy

es_conf

Nov 13th, 2015
148
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 1.74 KB | None
  1. index:
  2.   number_of_shards: 1
  3.   number_of_replicas: 0  # not for production
  4.  
  5.   analysis:
  6.     char_filter:
  7.       ru:
  8.         type: mapping
  9.         mappings: ['Ё=>Е', 'ё=>е']
  10.     analyzer:
  11.       tag_analyzer:
  12.         alias: [tag]
  13.         type: custom
  14.         tokenizer: nGram
  15.         filter: [tag_filter, russian_morphology, english_morphology]
  16.       default_index:
  17.         alias: [index_ru]
  18.         type: custom
  19.         tokenizer: nGram
  20.         filter: [stopwords_ru, custom_word_delimiter, lowercase, russian_morphology, english_morphology, translit]
  21.         char_filter: [ru]
  22.       default_search:
  23.         alias: [search_ru]
  24.         type: custom
  25.         tokenizer: standard
  26.         filter: [stopwords_ru, custom_word_delimiter, lowercase, russian_morphology,  english_morphology, translit]
  27.         char_filter: [ru]
  28.     tokenizer:
  29.       nGram:
  30.         type: nGram
  31.         min_gram: 4
  32.         max_gram: 20
  33.     filter:
  34.       translit:
  35.         type: icu_transform
  36.         id: Any-Latin; NFD; [:Nonspacing Mark:] Remove; NFC
  37.       tag_filter:
  38.         type: word_delimiter
  39.         type_table: ['# => ALPHA', '@ => ALPHA']
  40.       stopwords_ru:
  41.         type: stop
  42.         stopwords: _russian_
  43.         ignore_case: true
  44.       custom_word_delimiter:
  45.         type: word_delimiter
  46.         generate_word_parts: true
  47.         generate_number_parts: true  # "500-42" ⇒ "500" "42"
  48.         catenate_words: true  # "wi-fi" ⇒ "wifi"
  49.         catenate_numbers: false  # "500-42" ⇒ "50042"
  50.         catenate_all: true  # "wi-fi-4000" ⇒ "wifi4000"
  51.         split_on_case_change: true  # "PowerShot" ⇒ "Power" "Shot"
  52.         preserve_original: true  # "500-42" ⇒ "500-42" "500" "42"
  53.         split_on_numerics: false  # "j2se" ⇒ "j" "2" "se"
Advertisement
RAW Paste Data Copied
Advertisement