limestone
limestone copied to clipboard
Query weights differ from standard bin/search -- they are one-digit integers
First I want to say thank you very much for this library. It is immensely helpful and it's obvious the amount of work that went into it. Couldn't be more enthusiastic about being able to use it with our Node assets.
I have a small problem though. I see when searching for results with limestone I get a list sorted differently than with a standard bin/search operation. The results from limestone tend to be like this:
matches:
[ { doc: 28, weight: 2, attrs: {} },
{ doc: 18, weight: 1, attrs: {} },
{ doc: 41, weight: 1, attrs: {} },
{ doc: 71, weight: 1, attrs: {} },
But when I search with bin/search I get
displaying matches:
1. document=28, weight=2777
2. document=80, weight=1770
3. document=100, weight=1770
4. document=18, weight=1725
So not only are the weights reduced to a single digit, they are sorted differently. Is there a way I can get the standard 4-digit response weight? I tried different weighting algorithms but I don't believe that's the core issue. I believe it may be a matter of parsing the digits on their return from the server.
Can anyone shed some light? Thanks!
Is this guy alive? Anyone know CPR?
Hello. I'm alive but very busy with RL stuff. As for weights, i haven't updated this module for a while, but I think it's related to decoding of weights from binary. I have to look into the recent versions of Sphinx driver for possible changes, because I haven't updated this module for a while.