lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Hatcher <e...@ehatchersolutions.com>
Subject Re: Are similarity scores computed when using sort?
Date Sat, 27 Nov 2004 23:04:01 GMT
On Nov 27, 2004, at 1:01 PM, Aphinyanaphongs, Yindalon wrote:
> Thanks for the quick response.  I don't necessarily need to calculated 
> the similarity score. It was my understanding that the inverted index 
> had a list of all the hits for each term so technically, no document 
> returned from the inverted index should have a score of 0.

It's certainly true that the inverted index has a list of all documents 
that contain each term.  However the word "hit" is by definition a 
document with score > 0 given a query, not just a term.  Queries can be 
quite sophisticated.  For example, I was very easily able to create an 
XOR query by using a custom similarity.

> Would you know in what java class the call is made to Similarity and 
> where that code may be commented out, or would it be preferable to 
> write my own similarity sub-class instead?

Similarity use is spread out in several places.  Get a good IDE(A!) and 
surf the code and you'll easily be able to see where methods of 
Similarity are being used.

	Erik


---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-user-help@jakarta.apache.org


Mime
View raw message