Here is Finnish default config for text field, copied from Dutch and altered to Finnish. Seems to work quite well but Snowball filter may not work perfectly for Finnish stemming.

Comments

mErilainen created an issue. See original summary.

merilainen’s picture

Status: Active » Needs review
StatusFileSize
new8.44 KB
merilainen’s picture

StatusFileSize
new8.55 KB

Here is an updated patch with Edge NGram filter for better compound word matching.

mkalkbrenner’s picture

Status: Needs review » Needs work

Thanks for this great start! I wish others would do the same for other languages :-)
Here are some quick notes

  1. +++ b/config/optional/search_api_solr_multilingual.solr_field_type.text_fi_4_5_0.yml
    @@ -0,0 +1,493 @@
    +          class: solr.MappingCharFilterFactory
    +          mapping: accents_fi.txt
    ...
    +    hänessä
    ...
    +    # ä => a
    +    "\u00E4" => "a"
    

    I think there's an error in the char mapping. At least "ä" should be preserved and not be normalized to "a".

  2. +++ b/config/optional/search_api_solr_multilingual.solr_field_type.text_fi_4_5_0.yml
    @@ -0,0 +1,493 @@
    +          class: solr.DictionaryCompoundWordTokenFilterFactory
    +          dictionary: nouns_fi.txt
    ...
    +  nouns: |
    

    I don't know if Finish has compound words like German, but the nouns list must not be empty if you keep this filter.

merilainen’s picture

Status: Needs work » Needs review
StatusFileSize
new8.33 KB

I fixed the accents. I know the compound word filter requires a dictionary file, but NL didn't have any either and it won't break Solr. Edge NGram helps a little bit with the compound words, but it won't find them in the middle of the word. Anyway, here is the config without compound word filter. Maybe I will provide a better one if I come up with a better solution.

merilainen’s picture

StatusFileSize
new97.04 KB

Compound filter made a comeback, here with the list of nouns.

mkalkbrenner’s picture

I applied some changes on commit. Thanks for your contribution!

kekkis’s picture

I wonder, why has this been committed if it's still "Needs review"? Methinks the correct status would be "Fixed".

mkalkbrenner’s picture

Status: Needs review » Fixed

yep, you're right. thanks

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.