How can I boost the score for documents in which my query matches a particular field earlier. For example, searching for “super man” should give “super man returns” a higher score than “there is my super man”. Is this possible?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Solved it myself after reading a LOT about this online. What specifically helped me was a reply on nabble which goes like (I used dismax, so explaining that here):
"_START_ <actual data>""_START_ <actual query>"nameStringas one of the fields to look in in the query fields param (qf)nameStringwith a phrase slop of 1 or 2 (lower values would mean stricter searching)Your final query params will be something like: