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
making autosuggest results useful #157
Comments
Hello @joyously , There is definitely room to improve it, but I need actionable ideas. What specific kind of improvements would you suggest?
If you do make an elaborate filter that produces better results, please post it here because it could help me improve the standard algorithm. I am all for making it better. |
For my use case of a static blog search, I chose to use AND and
Basically, I discard all the terms for the first words and leave the ones for the last word being typed. |
Thank you @joyously , this is useful! I’ll try to take inspiration and come up with some improvements to the auto suggestions for the next release. |
@joyously I think that this configuration would achieve the same effect (minus the filtering for result having a score higher than 1/4 of the top score, which makes total sense but could be implementation dependent): combine with In code: miniSearch.autoSuggest(query, {
combineWith: 'AND',
fuzzy: false,
prefix: (term, i, terms) => i === terms.length - 1
}) If this really achieves the same effect, it could become the new default for auto suggestions. After all, combining with What do you think? |
One problem with making In sum, I am still undecided whether to use |
Ah, I was unaware of that. So I guess the documentation does need to mention which options affect the entire process and which are specific to the term, using examples for all the ways a user might configure (like one field or multiple). |
Yep I agree, I think the best course of action here is to clearly document how to achieve different behaviors. |
Oh, forget what I said... it turns out that the Using The point about improving documentation is still valid though. |
Closing after changing the default to Ideally, in the future more examples should be provided in a "how to" section, which would be useful also for other features. The new default is released in |
I'm struggling to get search suggestions that are useful.
It makes sense to me for the search to use AND, so I have set that for the search and tried both OR and AND for the suggestions. It seems to work okay in the demo, but my data is not simple title and artist like the demo. It is long articles of text.
I've tried various combinations of
prefix
andfuzzy
(mostly with AND), but the suggestions are not helpful to the user, because they have the first word followed by a bunch of possible matches for the second word. I can see how these terms are all found in one document, but the user is not helped by that suggestion.Even your example in the docs is confusing, where you call autosuggest for "zen ar" and get "zen art archery" as a suggestion. It makes sense once you know the parameters, but as a suggestion, it's not something you would click on. I think the user would be helped by showing "zen art" separate from "zen archery".
Do I need to make an elaborate filter to get suggestions that make sense?
The text was updated successfully, but these errors were encountered: