lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Hostetter <>
Subject Re: Recency weightage in Lucene
Date Mon, 19 Jun 2006 06:27:55 GMT

: Subject: Recency weightage in Lucene
: I am thinking of modifying lucene's current ranking algorithm to include
: the document's recency-weightage. So that the latest modified documents
: gets preference over earlier modified documents, which makes sense for
: news search.

FunctionQuery is your friend...

..It's part of the Solr project, but it's extremely generic and should be
usable out of the box with any Lucene app.

: requirement is that document's lastModifiedTime is stored in the doc's
: field, and extracting this value could be quite expensive for every
: iteration in its posting stream. One approach could be to store it in a
: separate file (like Normalization) to avoid field-lookup.

if you store it as an indexed field, you can use the FieldCache to access
it and it's a lot less expensive to look at at scoring time (if you look
at the FunctionQuery support classes, this is what the FieldCacheSource
class does)


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

View raw message