Posted on 04/08/2025 17:11:28
Hi Adrian
Sorry - this will be a bit technical....
To normalize romanian, you need to use an Analyzer that understands the romanian language - Lucene actually has that already:
https://github.com/apache/lucenenet/blob/master/src/Lucene.Net.Analysis.Common/Analysis/Ro/RomanianAnalyzer.cs
It uses a stemmer like this to handle Romanian:
https://github.com/apache/lucenenet/blob/master/src/Lucene.Net.Analysis.Common/Tartarus/Snowball/Ext/RomanianStemmer.cs
To use another analyzer than the "StandardAnalyzer" as Dynamicweb uses by default, you have to create a field type in Dynamicweb that uses another analyzer:

The problem is currently, that we only list analyzers that has parameter less constructors - which most of these analyzers do not have. That is why the list of potential analyzers is short.
Most of these analyzers have another constructor we can use - so I just made a change so we can list and use most analyzers in the lucene project. This requires a release from us.
If you cannot wait, you can make a copy of the RomanianAnalyzer from the above Git repo (Name it e.g. CustomRomanianAnalyzer), give it a constructor with no arguments that will call the current constructor with the value of Lucene.Net.Util.LuceneVersion field and upload that dll to DW - and you can use it right away,.
But as I wrote - we made the change so it will be rolling out end of month.
BR Nicolai