lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Taylor <paul_t...@fastmail.fm>
Subject Re: Anyway to not bother scoring less good matches ?
Date Wed, 04 May 2011 16:33:24 GMT
On 04/05/2011 15:02, Ahmet Arslan wrote:
>
>> Thanks for the hint, so this could be done by overriding getBooleanQuery() in QueryParser
?
>>
>
> I think something like this should do the trick. Without overriding anything.
>
>
> Query query= QueryParser.parse("User Entered String");
>
> if (query instanceof BooleanQuery)
> ((BooleanQuery)query).setMinimumNumberShouldMatch(3);
>
> You can steal code from solr too, ( e.g. how to calculate mm and optional clause count
etc.)
>
>
Thanks again, now done that but still not having much effect on total 
ime, but I havent analysed the results much yet maybe I dont quite have 
the algoithm quite right.

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


Mime
View raw message