lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jake Mannix <jake.man...@gmail.com>
Subject Re: "one of the terms"
Date Sat, 30 Jan 2010 05:39:01 GMT
coord won't help him, I don't think.

Doesn't he just want a DisjunctionMaxQuery instead of BooleanQuery?

  -jake

On Fri, Jan 29, 2010 at 9:28 PM, Otis Gospodnetic <
otis_gospodnetic@yahoo.com> wrote:

> Paul,
>
> Custom Similarity perhaps, oui.  Not 100% sure, maybe have this always
> return 1.0f.
>
>
>  /** Computes a score factor based on the fraction of all query terms that
> a
>   * document contains.  This value is multiplied into scores.
>   *
>   * The presence of a large portion of the query terms indicates a better
>   * match with the query, so implementations of this method usually return
>   * larger values when the ratio between these parameters is large and
> smaller
>   * values when the ratio between them is small.
>   *
>   * @param overlap the number of query terms matched in the document
>   * @param maxOverlap the total number of terms in the query
>   * @return a score factor based on term overlap with the query
>   */
>  public abstract float coord(int overlap, int maxOverlap);
>
> Otis
> ----
> Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
> Hadoop ecosystem search :: http://search-hadoop.com/
>
>
>
> ----- Original Message ----
> > From: Paul Libbrecht <paul@activemath.org>
> > To: java-user@lucene.apache.org
> > Sent: Fri, January 29, 2010 4:38:56 PM
> > Subject: "one of the terms"
> >
> >
> > Hello luceners,
> >
> > In our project, we are building queries from long list of possible terms
> > (expanded through ontology deduction). I would like, however, that the
> rank is
> > unaffected by the number of matches: one or thirty occurrences of one of
> the
> > many words should give the same score.
> >
> > Did someone make such a query already?
> > Should I "just craft the Similarity"? (I'd rather avoid it if possible)
> >
> > thanks in advance
> >
> > paul
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> > For additional commands, e-mail: java-user-help@lucene.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message