Macrons and search results in NZ

I found this old thread, which has now been closed, related to an issue we noticed on our site: Discourse should ignore if a character is accented when doing a search - Feature

In Te Reo Māori in New Zealand, there are two versions of each vowel – with and without a macron. The macron can change the meaning, but there are some common words used by our community where it would not. These are sometimes typed with the macron and sometimes without, in both topics and search. Therefore, like users in the above thread pointed out, searches including these words yield incomplete results.

I tried to follow the above thread to understand where you got to with this issue but not very clear on the answer. Is it/can it be possible to “ignore” diacritics in search, at least for a specific country or site? Or alternatively, is there any way for us to set this up for a specific list of words?

1 Like

I’m also in Aotearoa NZ; I hadn’t encountered this problem yet, but I can certainly reproduce it on our site:

Using ‘maori’ (without macron)

Using ‘māori’ (with macron)

However, it seems that the feature is already implemented, but not well documented. Look for the Search ignore accents site setting. I’ve moved your topic to Support as a result.

I’ve just turned it on for the first time, which will hopefully improve the search experience of our users. It hasn’t changed anything as yet, and I suspect that I’ll need to trigger a search index rebuild for it do so as per this:

2 Likes

Is this one where manually triggering the jobs::ReindexSearch job from your /sidekiq/scheduler page will help speed this up?

How do you do that?

If you have access to your YourSite/sidekiq/scheduler page you can manually trigger some of the background jobs to reduce the natural wait time.

I like to use the browser ‘find in page’ to help find the one I’m looking for rather than pick from the list.

Whichever way you locate the job you’re looking for, you can then manually Trigger it to run it immediately rather than wait for the next scheduled occurrence.

(I’m not 100% sure it will be the magic bullet in this case, but it may be worth a try just in case :crossed_fingers: There’s also no additional instructions about extra steps in the Search ignore accents setting description itself, so I’m hoping there’s some background magic that powers it :slight_smile:)

1 Like

Ok, that seemed pretty simple. I suspect that it is only the light version though as it only took 162 milliseconds! I can imagine that a full re-index would take some serious grunt for a while.

Certainly, it didn’t seem to change anything.

I’ll run the rake task late tonight at a safe time and let you know how it gets on.

1 Like

Ah, I thought it might be too optimistic. :slight_smile: The site settings that need a rake task running after enabling/disabling often have a hint in the setting description (eg. Add rel nofollow to user content or spoiler enabled). If you do need the rake task for this one then adding that to the setting description like the others may be a useful addition.

1 Like

@marvi given you are hosted with us we can ensure someone reindexes your site, do you mind shooting an email to team@dscourse.org?

2 Likes