lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yonik Seeley (JIRA)" <>
Subject [jira] Commented: (LUCENE-446) FunctionQuery - score based on field value
Date Sat, 24 Mar 2007 20:38:32 GMT


Yonik Seeley commented on LUCENE-446:

> i think once upon a time Yonik held off because he wasn't sure if he liked the API

Right... it's just never been at the top of my list to revisit.

The main thing I was wondering is if I should have a whole ValueSource thing... perhaps FunctionQuery
should be able to use other Queries directly.  For example, one could have
MultiplyFunctionQuery(MyNormalQuery, MyFieldFunctionQuery) to boost a query by another query
(in this case a function query).

Right now, increasing the score of a document based on a field value is done in an additive
way by adding a FunctionQuery clause to a BooleanQuery.  One could create a ValueSource that
wraps another query to get a multiplicative effect, but is that the simplest approach?

> FunctionQuery - score based on field value
> ------------------------------------------
>                 Key: LUCENE-446
>                 URL:
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>    Affects Versions: 1.9
>            Reporter: Yonik Seeley
>         Attachments:,
> FunctionQuery can return a score based on a field's value or on it's ordinal value.
> FunctionFactory subclasses define the details of the function.  There is currently a
LinearFloatFunction (a line specified by slope and intercept).
> Field values are typically obtained from FieldValueSourceFactory.  Implementations include
FloatFieldSource, IntFieldSource, and OrdFieldSource.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message