I'm building a customized e-commerce website and using SOLR (4.8.1) for indexing/searching products.
I want to provide a search field with autocomplete to help users by prompting suggestions, as they type:
- Display search suggestions (terms/phrases) [top 5]
- Display items suggestions [top 5]
Just like in this example (taken from www.extra.com.br)
The second part (products suggestions) is easy, basically is just querying SOLR as a normal search would do and taking the top 5.
The first part (queries suggestions) that's keeping me awake at night :)
I've already tried some alternatives, like Suggester component (/suggest) and also trying the regular search (/select) with facets.
I've accomplished to get suggestions for individual words, but what I REALLY WANT is predictive suggestions, like the print above. If the user types "monit", it brings suggestions of queries/products based on products that really exists. If user types "monitor banana", for example, it should bring nothing (because it doesn't exists), but in my case it's suggesting "monitor banana" because the 2 words exists separately in the index. (even having no relationship between them)
Can anyone point me in the right direction to accomplish this? A tutorial with an example (or even a book) would be very appreciated.
To make clear what I need, exactly what Google Commerce Search offered (I think they've discontinued it): https://www.youtube.com/watch?v=nje9fUcIkKc
Thank you!