-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Exact search in Sphinx #3301
Comments
AFAIK, there are no way to do that. |
Currently, the search index maps single words to .rst/html files. For example, the search index "knows" that:
It knows little more. If one wants to support exact searches for multiple-word strings, one needs to add the position of each word to the search index. If this doesn't increase the index size too much, it might be practicable approach. @tk0miya Do you think it is worth to look further into this? |
Dataverse uses Sphinx (version 1.5.6) for its documentation, and we're very interested in allowing our users to do this kind of exact phrase searching. It would make it much easier for our users to quickly find exactly the information they're looking for in our documentation. For the record, we're also interested in boolean search operators like AND, OR, and NOT, but this exact phrase searching is most important for us. Here is our issue on the subject in our repo: IQSS/dataverse#4884 Here is an example of our use case: One of our users searched for "terms of use" in quotations. This is what happens when you attempt this query in our current sphinx search: As you can see, this currently returns a useless list of all pages that use the words "use", "user", "used", etc. However, there are plenty of relevant sections about Terms of Use on our guides that are being drowned out. When I search "terms of use" using quotes on my local copy of the guides using SublimeText's search feature, I get these useful results: An exact phrase search would go a long way for cases like this. |
👍 |
Subject:
Problem
Environment info
The text was updated successfully, but these errors were encountered: