You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by GitBox <gi...@apache.org> on 2019/12/17 06:11:08 UTC

[GitHub] [lucene-solr] pipcet commented on a change in pull request #1045: LUCENE-9072: Find matching terms from Matches API

pipcet commented on a change in pull request #1045: LUCENE-9072: Find matching terms from Matches API
URL: https://github.com/apache/lucene-solr/pull/1045#discussion_r358616667
 
 

 ##########
 File path: lucene/core/src/java/org/apache/lucene/search/Matches.java
 ##########
 @@ -44,4 +47,9 @@
    */
   Collection<Matches> getSubMatches();
 
+  /**
+   * Find all matching terms
+   */
+  void getMatchingTerms(Consumer<Term> termsConsumer) throws IOException;
+
 
 Review comment:
   Wouldn't this make more sense as a method of `MatchesIterator`?
   
   In conjunction with some changes to `PhraseWeight` and `SloppyPhraseMatcher`, that would allow us to accurately capture reordered phrases, which I think `getMatchingTerms` would be a good API for.
   
   My proposed use case is to modify `AnalyzingInfixSuggester` to use a `PhraseQuery` (with slop) and expose this data in order to suggest a reordered phrase to the user without including the entire document in the response.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org