Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rankmode default value not set #21

Open
dbrgn opened this issue Feb 25, 2011 · 1 comment
Open

rankmode default value not set #21

dbrgn opened this issue Feb 25, 2011 · 1 comment

Comments

@dbrgn
Copy link

dbrgn commented Feb 25, 2011

In the sourcecode, I found

SPH_RANK_PROXIMITY_BM25 = 0 # default mode, (...)

But when not setting rankmode in my model, ranking does not occur, all weight values are set to 1.

@dbrgn
Copy link
Author

dbrgn commented Apr 15, 2011

Actually the default mode gets set to 2 (SPH_RANK_NONE).

>>> Company.search.query('UBS AG')._rankmode
2

That has a strong effect on search results.

Workaround is to set rankmode = u'SPH_RANK_PROXIMITY_BM25' in the model's SphinxSearch instance.

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

No branches or pull requests

1 participant