Add document-oriented completion suggester#14410
Merged
areek merged 11 commits intoelastic:masterfrom Nov 7, 2015
Merged
Conversation
Contributor
There was a problem hiding this comment.
can we just initialize this with new HashMap<>() and make it final?
Contributor
|
LGTM, thanks @areek! Nice to see we can now remove two forked Lucene classes, the custom postings format, and cutover to Lucene's impls instead. |
Contributor
|
I left two minor comments on the latest commits, this LGTM too and doesn't need another review. Please go ahead and merge after the comments are fixed |
The completion suggester provides auto-complete/search-as-you-type functionality. This is a navigational feature to guide users to relevant results as they are typing, improving search precision. It is not meant for spell correction or did-you-mean functionality like the term or phrase suggesters. The completions are indexed as a weighted FST (finite state transducer) to provide fast Top N prefix-based searches suitable for serving relevant results as a user types. closes elastic#10746
a644e0a to
6444194
Compare
Contributor
|
Was this prematurely merged? I'm still pretty concerned about removing the payloads ability the users have now without concrete numbers that show the speed is the same. See comments on #10746 |
Contributor
|
This was originally merged into 2.2, but has been backed out in #16170 and so is in master only. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds document-oriented completion suggester (see #10746), replacing the previous completion suggester implementation from master.
This PR contains the changes from
feature/completion_suggester_v2branch (#11740 and #13659). Apart from code simplifications and bug fixes, the only functional change this adds is a collector which collects top N documents instead of top N suggestions. This was needed to ensure suggestion with multiple contexts would count as one suggestion. The change is contained in CompletionSuggester.java.The 2.x branch and 2.1 branch for this feature implements the new completion suggester in a bwc way and allows the old suggester to be used if
created in a previous version.
closes #10746