Loading config/optional/search_api_solr.solr_field_type.text_uk_6_0_0.yml +4 −6 Changes for config/optional/search_api_solr.solr_field_type.text_uk_6_0_0.yml: 4 added lines, 6 removed lines. Original line number Diff line number Diff line Loading @@ -39,9 +39,8 @@ field_type: ignoreCase: true words: stopwords_uk.txt - class: solr.SnowballPorterFilterFactory language: Russian protected: protwords_uk.txt class: solr.MorphologikFilterFactory dictionary: ukrainian.dict - class: solr.RemoveDuplicatesTokenFilterFactory - Loading Loading @@ -71,9 +70,8 @@ field_type: ignoreCase: true words: stopwords_uk.txt - class: solr.SnowballPorterFilterFactory language: Russian protected: protwords_uk.txt class: solr.MorphologikFilterFactory dictionary: ukrainian.dict - class: solr.RemoveDuplicatesTokenFilterFactory unstemmed_field_type: Loading config/optional/search_api_solr.solr_field_type.text_uk_7_0_0.yml +4 −6 Changes for config/optional/search_api_solr.solr_field_type.text_uk_7_0_0.yml: 4 added lines, 6 removed lines. Original line number Diff line number Diff line Loading @@ -39,9 +39,8 @@ field_type: ignoreCase: true words: stopwords_uk.txt - class: solr.SnowballPorterFilterFactory language: Russian protected: protwords_uk.txt class: solr.MorphologikFilterFactory dictionary: ukrainian.dict - class: solr.RemoveDuplicatesTokenFilterFactory - Loading Loading @@ -71,9 +70,8 @@ field_type: ignoreCase: true words: stopwords_uk.txt - class: solr.SnowballPorterFilterFactory language: Russian protected: protwords_uk.txt class: solr.MorphologikFilterFactory dictionary: ukrainian.dict - class: solr.RemoveDuplicatesTokenFilterFactory unstemmed_field_type: Loading config/schema/solr_field_type.schema.yml +1 −1 Changes for config/schema/solr_field_type.schema.yml: 1 added line, 1 removed line. Original line number Diff line number Diff line Loading @@ -246,7 +246,7 @@ search_api_solr.solr_field_type_filters: nullable: true dictionary: type: string label: 'OpenNLPLemmatizerFilter:: HunspellStemFilter:: DictionaryCompoundWordTokenFilter::dictionary' label: 'OpenNLPLemmatizerFilter:: HunspellStemFilter:: MorphologikFilterFactory:: DictionaryCompoundWordTokenFilter::dictionary' nullable: true lemmatizerModel: type: string Loading search_api_solr.install +29 −0 Changes for search_api_solr.install: 29 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -1199,3 +1199,32 @@ function search_api_solr_update_8315() { } } } /** * Use Ukrainian lemmatization instead of Russian SnowballPorterFilterFactory. */ function search_api_solr_update_8316() { foreach (search_api_solr_update_helper_get_field_type_configs() as $field_type_name => $field_type_config) { if ('uk' === $field_type_config['field_type_language_code']) { if (!empty($field_type_config['field_type'])) { foreach ($field_type_config['field_type'] as &$components) { if (is_array($components)) { foreach ($components as &$analyzers) { if (is_array($analyzers)) { foreach ($analyzers['filters'] as $key => &$filter) { if ('solr.SnowballPorterFilterFactory' === $filter['class']) { $filter['class'] = 'solr.MorphologikFilterFactory'; unset($filter['language']); unset($filter['protected']); $filter['dictionary'] = 'ukrainian.dict'; } } } } } } search_api_solr_update_helper_save_field_type_config($field_type_name, $field_type_config); } } } } Loading
config/optional/search_api_solr.solr_field_type.text_uk_6_0_0.yml +4 −6 Changes for config/optional/search_api_solr.solr_field_type.text_uk_6_0_0.yml: 4 added lines, 6 removed lines. Original line number Diff line number Diff line Loading @@ -39,9 +39,8 @@ field_type: ignoreCase: true words: stopwords_uk.txt - class: solr.SnowballPorterFilterFactory language: Russian protected: protwords_uk.txt class: solr.MorphologikFilterFactory dictionary: ukrainian.dict - class: solr.RemoveDuplicatesTokenFilterFactory - Loading Loading @@ -71,9 +70,8 @@ field_type: ignoreCase: true words: stopwords_uk.txt - class: solr.SnowballPorterFilterFactory language: Russian protected: protwords_uk.txt class: solr.MorphologikFilterFactory dictionary: ukrainian.dict - class: solr.RemoveDuplicatesTokenFilterFactory unstemmed_field_type: Loading
config/optional/search_api_solr.solr_field_type.text_uk_7_0_0.yml +4 −6 Changes for config/optional/search_api_solr.solr_field_type.text_uk_7_0_0.yml: 4 added lines, 6 removed lines. Original line number Diff line number Diff line Loading @@ -39,9 +39,8 @@ field_type: ignoreCase: true words: stopwords_uk.txt - class: solr.SnowballPorterFilterFactory language: Russian protected: protwords_uk.txt class: solr.MorphologikFilterFactory dictionary: ukrainian.dict - class: solr.RemoveDuplicatesTokenFilterFactory - Loading Loading @@ -71,9 +70,8 @@ field_type: ignoreCase: true words: stopwords_uk.txt - class: solr.SnowballPorterFilterFactory language: Russian protected: protwords_uk.txt class: solr.MorphologikFilterFactory dictionary: ukrainian.dict - class: solr.RemoveDuplicatesTokenFilterFactory unstemmed_field_type: Loading
config/schema/solr_field_type.schema.yml +1 −1 Changes for config/schema/solr_field_type.schema.yml: 1 added line, 1 removed line. Original line number Diff line number Diff line Loading @@ -246,7 +246,7 @@ search_api_solr.solr_field_type_filters: nullable: true dictionary: type: string label: 'OpenNLPLemmatizerFilter:: HunspellStemFilter:: DictionaryCompoundWordTokenFilter::dictionary' label: 'OpenNLPLemmatizerFilter:: HunspellStemFilter:: MorphologikFilterFactory:: DictionaryCompoundWordTokenFilter::dictionary' nullable: true lemmatizerModel: type: string Loading
search_api_solr.install +29 −0 Changes for search_api_solr.install: 29 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -1199,3 +1199,32 @@ function search_api_solr_update_8315() { } } } /** * Use Ukrainian lemmatization instead of Russian SnowballPorterFilterFactory. */ function search_api_solr_update_8316() { foreach (search_api_solr_update_helper_get_field_type_configs() as $field_type_name => $field_type_config) { if ('uk' === $field_type_config['field_type_language_code']) { if (!empty($field_type_config['field_type'])) { foreach ($field_type_config['field_type'] as &$components) { if (is_array($components)) { foreach ($components as &$analyzers) { if (is_array($analyzers)) { foreach ($analyzers['filters'] as $key => &$filter) { if ('solr.SnowballPorterFilterFactory' === $filter['class']) { $filter['class'] = 'solr.MorphologikFilterFactory'; unset($filter['language']); unset($filter['protected']); $filter['dictionary'] = 'ukrainian.dict'; } } } } } } search_api_solr_update_helper_save_field_type_config($field_type_name, $field_type_config); } } } }