question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

making autosuggest results useful

See original GitHub issue

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 and fuzzy (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?

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:11 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
lucaongcommented, Jun 13, 2022

Closing after changing the default to combineWith: 'AND' in #161 and adding some more documentation.

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 v5.0.0-beta3.

1reaction
lucaongcommented, Jun 13, 2022

Oh, forget what I said… it turns out that the beatles lucy di example is confusing, as the demo dataset only includes “Lucy in the Sky with Diamonds” from Elton John, not the original by The Beatles.

Using combineWith: 'AND' does include results where all terms are present, even in different fields. Therefore, it seems a good default for the auto suggestion.

The point about improving documentation is still valid though.

Read more comments on GitHub >

github_iconTop Results From Across the Web

10 Autocomplete Search Best Practices - How Predictive ...
In short: by making search faster and ensuring relevant results, autocomplete will decrease exit rate, increase conversion rate and likely even your average ......
Read more >
Best Practices: Designing autosuggest experiences
Here are some best practices recommended for the search bar & autosuggest patterns based on the analysis of user-typed queries & query formulation...
Read more >
What is Autocomplete Search? How Does it work? - AddSearch
Autocomplete in search is a pattern used to display query suggestions. Learn more about how to use search autocomplete on your website.
Read more >
How Google autocomplete works in Search
Autocomplete is a feature within Google Search designed to make it faster to complete searches that you're beginning to type.
Read more >
Auto suggest: best practices for autocomplete suggestion
How to design autocomplete in a search engine so your website users find what ... Useful for: Making search suggestion lists more palatable....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found