The only Query that currently utilizes the scorePayload functionality
is the BoostingTermQuery. I guess I would have a look at that as a
starting point.
On Feb 13, 2008, at 8:11 PM, Cedric Ho wrote:
I am using Lucene's Built-in query classes: TernQuery, PhraseQuery,
WildcardQuery, BooleanQuery and many of the SpanQueries.
The info I am going to pass in is just some weightings for different
part of the indexed contents. For example if the payload indicate that
a term is in the 2nd paragraph, then I'll take the weighting for the
2nd paragraph and multiply it by the score.
So it seems without writing my own query there's no way to do it ?
Cedric
On Feb 13, 2008 7:53 PM, Grant Ingersoll <[EMAIL PROTECTED]> wrote:
Are you writing your own Query? What kind of info did you have in
mind? scorePayload is called from the query scoring class, so I am
not sure how you would pass in info to it unless you were writing
your
own Query class.
-Grant
On Feb 13, 2008, at 4:31 AM, Cedric Ho wrote:
Hi all,
My problem is I have some additional weighting info that come with
each search. And I need to take both the weighting info and the
payload to calculate scores.
So how do I access the weighting info in
Similarity.scorePayload(String,byte[],int,int) ? I've thought about
using a ThreadLocal, but this seems like a hack, are there better
options ?
Regards,
Cedric
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------
Grant Ingersoll
http://lucene.grantingersoll.com
http://www.lucenebootcamp.com
Lucene Helpful Hints:
http://wiki.apache.org/lucene-java/BasicsOfPerformance
http://wiki.apache.org/lucene-java/LuceneFAQ
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]