-
Notifications
You must be signed in to change notification settings - Fork 25.2k
Support autocomplete indexes on select fields #2671
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
Comments
This has been brought up before on mailing lists. The best post I found was Cleo or ElasticSearch with NGram. With the new patch from issue #2674, this feature is very close to supportable. It's likely that a few borrowings from the Cleo codebase would finish the feature. |
Some of the API for issue #2709 may be relevant. |
It seems like performance issues partly addressed by issue #988 improvements in Lucene. Simply, bool.must.wildcard on a lowercase filtered + camel case analyzed field works quite well over a medium sized set of documents. |
@Downchuck another option is to simply use edge ngrams analysis on the relevant field you wish to do autocomplete on. |
ES has this thoroughly handled, closing the bug. |
The LinkedIn Cleo project provides type-ahead indexes on set fields, a very handy feature for certain circumstances. This has come up for me in a project where one of the fields is essentially a dynamic enumeration of about five thousand entries; names of people and companies and the like. The Cleo project is available under Apache 2.0, should ES authors see fit to borrow any of its components to fulfill this feature request. ES already has its own Bloom implementation.
An auto-complete search request would allow me to say field X must equal "Z" and field "Y" is the field which I'm running the auto-complete request on.
Example record: { assigned_rep: "Bob", company: "Tractor mowing", company_tokens: ["tractor","mowing","lawn"] }.
My search index would be on assigned_rep and company_tokens. I would pass assigned_rep = Bob and autocomplete_search on company_tokens for "Law", which would match on "lawn" and return the full record (and any other matches).
The text was updated successfully, but these errors were encountered: