fergiemcdowall / search-index

A persistent, network resilient, full text search library for the browser and Node.js

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Release of Version 3

tonprince opened this issue · comments

commented

I was wondering if there is a roadmap for the release of version 3, as I am looking for support of query like: "koh tao", phrase with 2 words.

With version 2 it is not supported, and even the workaround to put a delimiter like '_' or '-' does not work.

I tried to check with milestone from version 3, but it seams it is not stable yet as basic query does not work.

Hi @tonprince

Phrase search only works if you index the phrase.

So when indexing:

{
  text: ['koh', 'tao']    // only gives hits for 'koh' and 'tao'
}

and:

{
  text: ['koh', 'tao', 'koh tao']    // gives hits for 'koh' and 'tao' and the phrase 'koh tao'
}

Use something like ngraminator to create the phrases (n-grams).

Here is the scrum board for search-index@3

For some reason you need to reload the page to not only get an empty scrumboard =)

If you use ngraminator, you need to join the phrases arrays afterwords I think. You can check out how ngraminator works here: https://eklem.github.io/daq-proc/demo/document-processing/

commented

Thanks