Hi
Take a look at PhraseQuery or SpanNearQuery, particularly the setSlop() methods and the inOrder flag on the latter. http://www.lucidimagination.com/blog/2009/07/18/the-spanquery/ is well worth reading. -- Ian. On Mon, May 3, 2010 at 8:20 PM, Pablo <pablo.queixa...@gmail.com> wrote: > Hello, > > Lucene core doesn't seems to use relative word positioning (?) for scoring. > > For example, indexing that phrase "a b c d e f g h i j k l m n o p q r > s t u v w x y z", these queries give the same results (0.19308087) : > - 1 : phrase:'e f g' > - 2 : phrase:'o k z' > > I'm a bit familiar with lucene and snowballs, but I never (really) > needed this feature before, and didn't browse the lucene contribs. > > Maybe I'm misunderstanding something, but, what can I do to obtain > query 1 get a better score than the second ? > > Should I implement a Scorer and or a Similarity, or can an analyser > and a specific stemmer be sufficient? > > > Thanks, [I first wrote to dev, wasn't the right place.] > > Pablo > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org > For additional commands, e-mail: java-user-h...@lucene.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org