[ https://issues.apache.org/jira/browse/LUCENE-8343?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16549498#comment-16549498 ]
Michael McCandless commented on LUCENE-8343: -------------------------------------------- Hi [~alessandro.benedetti], it looks like there are some {{ant precommit}} failures with the patch: {noformat} [forbidden-apis] Forbidden method invocation: java.lang.Long#<init>(long) [Constructors for wrapper classes of Java primitives should be avoided in fav\ or of the public static methods available or autoboxing] [forbidden-apis] in org.apache.lucene.search.suggest.fst.FSTCompletionTest (FSTCompletionTest.java:34) [forbidden-apis] Forbidden method invocation: java.lang.Long#<init>(long) [Constructors for wrapper classes of Java primitives should be avoided in fav\ or of the public static methods available or autoboxing] [forbidden-apis] in org.apache.lucene.search.suggest.Input (Input.java:57) [forbidden-apis] Forbidden method invocation: java.lang.Long#<init>(long) [Constructors for wrapper classes of Java primitives should be avoided in fav\ or of the public static methods available or autoboxing] [forbidden-apis] in org.apache.lucene.search.suggest.PersistenceTest (PersistenceTest.java:82) [forbidden-apis] Forbidden method invocation: java.lang.Long#<init>(long) [Constructors for wrapper classes of Java primitives should be avoided in fav\ or of the public static methods available or autoboxing] [forbidden-apis] in org.apache.lucene.search.suggest.analyzing.FuzzySuggesterTest (FuzzySuggesterTest.java:971) [forbidden-apis] Forbidden method invocation: java.lang.Long#<init>(long) [Constructors for wrapper classes of Java primitives should be avoided in fav\ or of the public static methods available or autoboxing] [forbidden-apis] in org.apache.lucene.search.suggest.FileDictionaryTest (FileDictionaryTest.java:88) [forbidden-apis] Forbidden method invocation: java.lang.Long#<init>(long) [Constructors for wrapper classes of Java primitives should be avoided in fav\ or of the public static methods available or autoboxing] [forbidden-apis] in org.apache.lucene.search.suggest.FileDictionaryTest (FileDictionaryTest.java:110) [forbidden-apis] Forbidden method invocation: java.lang.Long#<init>(long) [Constructors for wrapper classes of Java primitives should be avoided in fav\ or of the public static methods available or autoboxing] [forbidden-apis] in org.apache.lucene.search.suggest.DocumentValueSourceDictionaryTest (DocumentValueSourceDictionaryTest.java:508) [forbidden-apis] Forbidden method invocation: java.lang.Long#<init>(long) [Constructors for wrapper classes of Java primitives should be avoided in fav\ or of the public static methods available or autoboxing] [forbidden-apis] in org.apache.lucene.search.suggest.DocumentValueSourceDictionaryTest (DocumentValueSourceDictionaryTest.java:538) [forbidden-apis] Scanned 229 class file(s) for forbidden API invocations (in 0.06s), 8 error(s).{noformat} which was a recent change to Lucene. Can you please fix these? Thanks. > BlendedInfixSuggester bad score calculus for certain suggestion weights > ----------------------------------------------------------------------- > > Key: LUCENE-8343 > URL: https://issues.apache.org/jira/browse/LUCENE-8343 > Project: Lucene - Core > Issue Type: Bug > Components: core/search > Affects Versions: 7.3.1 > Reporter: Alessandro Benedetti > Priority: Major > Attachments: LUCENE-8343.patch, LUCENE-8343.patch, LUCENE-8343.patch, > LUCENE-8343.patch > > Time Spent: 20m > Remaining Estimate: 0h > > Currently the BlendedInfixSuggester return a (long) score to rank the > suggestions. > This score is calculated as a multiplication between : > long *Weight* : the suggestion weight, coming from a document field, it can > be any long value ( including 1, 0,.. ) > double *Coefficient* : 0<=x<=1, calculated based on the position match, > earlier the better > The resulting score is a long, which means that at the moment, any weight<10 > can bring inconsistencies. > *Edge cases* > Weight =1 > Score = 1( if we have a match at the beginning of the suggestion) or 0 ( for > any other match) > Weight =0 > Score = 0 ( independently of the position match coefficient) -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org