orama icon indicating copy to clipboard operation
orama copied to clipboard

Sequential match priority

Open micheleriva opened this issue 3 years ago • 2 comments

Is your feature request related to a problem? Please describe. As for now, Lyra performs searches on individual tokens.

So for example, if I have the following documents:

  • "Hello everyone here. My name is Michele"
  • "Hello Michele"

When searching for the term "Hello Michele", there's still a chance to get the first document. We should take into account that we want to find the documents and tokens in a precise order

micheleriva avatar Jul 15 '22 12:07 micheleriva

For future me: I would consider the possibility of using an n-gram algorithm for that. Index size will increase, but it might be worth it.

micheleriva avatar Jul 15 '22 16:07 micheleriva

I know how this is gonna end

7zyychkxcg591

micheleriva avatar Jul 15 '22 16:07 micheleriva