> I’m using Lucene 2.4.1 and I’m trying to use a custom
> HitCollector to collect only the first N hits (not the best hits) for
> performance. 

You mean that you do not need score calculation therefore you do not want 
results sorted by relevancy. Just you need is a Boolean Retrieval Model, right? 
All results will have ConstantScore (0 or 1).

If yes, I think omitting norms and tfs of your searchable fields can improve 
your search performance without writing custom HitCollector.



void org.apache.lucene.document.Field.setOmitNorms(true) 
Using Field.Index.ANALYZED_NO_NORMS in constructor.
void org.apache.lucene.document.Field.setOmitTf(true)  


But i am not sure those changes are enough to convert Vector Space Model to 
Boolean Retrieval Model. I think there should be another trick to not to 
calculate score/similarity at all. 

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org
For additional commands, e-mail: java-user-h...@lucene.apache.org

Reply via email to