Skip to content

Update the omni search for romanized gurmukhi#300

Open
Gauravjeetsingh wants to merge 6 commits intoKhalisFoundation:devfrom
Gauravjeetsingh:omni-search-fix
Open

Update the omni search for romanized gurmukhi#300
Gauravjeetsingh wants to merge 6 commits intoKhalisFoundation:devfrom
Gauravjeetsingh:omni-search-fix

Conversation

@Gauravjeetsingh
Copy link
Copy Markdown
Collaborator

@Gauravjeetsingh Gauravjeetsingh commented Dec 11, 2025

Search the meilisearch with phonetic search, transliteration and the first letters.
And then combine all results based on their match score for the final results.

Also, update the API's compatibilty to support Node js 22

@Gauravjeetsingh Gauravjeetsingh self-assigned this Dec 11, 2025
Comment on lines +13 to 17
103: '090', // ਸ: 'ਸ਼'
106: '122', // ਖ: 'ਖ਼'
115: '083', // ਗ: 'ਗ਼'
'075': '094', // ਜ: 'ਜ਼'
'080': '038', // ਫ: 'ਫ਼'
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should all of these keys have string data type for consistency?

Comment thread tests/e2e/utils.js
@@ -1,4 +1,4 @@
import fetch from 'node-fetch';
// Native fetch is available in Node 18+
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line can be removed. Node 18 has reached EOL one year ago.

Comment thread api/controllers/omni.js Outdated
matchingStrategy: 'all',
};

const phonticParams = {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

phoneticParams*

Comment thread api/controllers/omni.js Outdated
};

const phonticParams = {
limit: 40,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should it be 40 for prod as well?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it would be 40, also updated the search flow

Comment thread api/controllers/omni.js Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants