You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Atri Sharma <at...@apache.org> on 2019/06/26 16:48:27 UTC
Re: how to find out each score contribution from booleanquery components
It depends a lot on the actual clauses (whether they are SHOULD, MUST,
MUST_NOT), each query’s type (phrase, term etc).
Could you post your query and the explain plan of IndexSearcher post the
rewrite?
On Wed, 26 Jun 2019 at 6:46 PM, <ba...@oracle.com> wrote:
> Hi,-
>
> how can one find out each score contribution from booleanquery
> components?
>
> Best regards
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
> --
Regards,
Atri
Apache Concerted
Re: how to find out each score contribution from booleanquery
components
Posted by ba...@oracle.com.
This is a nested (2-level in this case) booleanquery.
Best regards
On 6/26/19 1:06 PM, baris.kazar@oracle.com wrote:
> Sure, here is the query plan: (i cant run explain plan as it does not
> give me anything)
>
> [+streetDFLT:maink~2 (streetDFLT:"maine")^0.35, +cityDFLT:nasua~2
> (cityDFLT:"nasuh")^0.35, ++regionDFLT:"new-hampshire"
> (regionDFLT:"new-hammpshire")^0.98, ++countryDFLT:"united"
> (countryDFLT:"uniten")^0.42000002 +countryDFLT:"states"
> (countryDFLT:"statesir")^0.56]
>
>
> explain plan gives:
>
> Explanation expl = is.explain(booleanQuery.build(), 10);
> System.out.println(expl);
>
> This prints:
>
> 0.0 = Failure to meet condition(s) of required/prohibited clause(s)
> 0.0 = no match on required clause (+regionDFLT:new-hampshire
> (regionDFLT:new-hammpshire)^0.98)
> 0.0 = Failure to meet condition(s) of required/prohibited clause(s)
> 0.0 = no match on required clause (regionDFLT:new-hampshire)
> 0.0 = no matching term
> 0.0 = no match on required clause (+countryDFLT:united
> (countryDFLT:uniten)^0.42000002 +countryDFLT:states
> (countryDFLT:statesir)^0.56)
> 0.0 = Failure to meet condition(s) of required/prohibited clause(s)
> 0.0 = no match on required clause (countryDFLT:united)
> 0.0 = no matching term
> 0.0 = no match on required clause (countryDFLT:states)
> 0.0 = no matching term
>
>
> Best regards
>
>
> On 6/26/19 12:48 PM, Atri Sharma wrote:
>> It depends a lot on the actual clauses (whether they are SHOULD, MUST,
>> MUST_NOT), each query’s type (phrase, term etc).
>>
>> Could you post your query and the explain plan of IndexSearcher post the
>> rewrite?
>>
>> On Wed, 26 Jun 2019 at 6:46 PM, <ba...@oracle.com> wrote:
>>
>>> Hi,-
>>>
>>> how can one find out each score contribution from booleanquery
>>> components?
>>>
>>> Best regards
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
>>> For additional commands, e-mail: java-user-help@lucene.apache.org
>>>
>>> --
>> Regards,
>>
>> Atri
>> Apache Concerted
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org
Re: how to find out each score contribution from booleanquery components
Posted by Atri Sharma <at...@apache.org>.
It seems evident that multiple of your Must clauses are not matching any
document, hence no results are being returned?
On Wed, 26 Jun 2019 at 6:51 PM, <ba...@oracle.com> wrote:
> Sure, here is the query plan: (i cant run explain plan as it does not
> give me anything)
>
> [+streetDFLT:maink~2 (streetDFLT:"maine")^0.35, +cityDFLT:nasua~2
> (cityDFLT:"nasuh")^0.35, ++regionDFLT:"new-hampshire"
> (regionDFLT:"new-hammpshire")^0.98, ++countryDFLT:"united"
> (countryDFLT:"uniten")^0.42000002 +countryDFLT:"states"
> (countryDFLT:"statesir")^0.56]
>
>
> explain plan gives:
>
> Explanation expl = is.explain(booleanQuery.build(), 10);
> System.out.println(expl);
>
> This prints:
>
> 0.0 = Failure to meet condition(s) of required/prohibited clause(s)
> 0.0 = no match on required clause (+regionDFLT:new-hampshire
> (regionDFLT:new-hammpshire)^0.98)
> 0.0 = Failure to meet condition(s) of required/prohibited clause(s)
> 0.0 = no match on required clause (regionDFLT:new-hampshire)
> 0.0 = no matching term
> 0.0 = no match on required clause (+countryDFLT:united
> (countryDFLT:uniten)^0.42000002 +countryDFLT:states
> (countryDFLT:statesir)^0.56)
> 0.0 = Failure to meet condition(s) of required/prohibited clause(s)
> 0.0 = no match on required clause (countryDFLT:united)
> 0.0 = no matching term
> 0.0 = no match on required clause (countryDFLT:states)
> 0.0 = no matching term
>
>
> Best regards
>
>
> On 6/26/19 12:48 PM, Atri Sharma wrote:
> > It depends a lot on the actual clauses (whether they are SHOULD, MUST,
> > MUST_NOT), each query’s type (phrase, term etc).
> >
> > Could you post your query and the explain plan of IndexSearcher post the
> > rewrite?
> >
> > On Wed, 26 Jun 2019 at 6:46 PM, <ba...@oracle.com> wrote:
> >
> >> Hi,-
> >>
> >> how can one find out each score contribution from booleanquery
> >> components?
> >>
> >> Best regards
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> >> For additional commands, e-mail: java-user-help@lucene.apache.org
> >>
> >> --
> > Regards,
> >
> > Atri
> > Apache Concerted
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
> --
Regards,
Atri
Apache Concerted
Re: how to find out each score contribution from booleanquery
components
Posted by ba...@oracle.com.
Sure, here is the query plan: (i cant run explain plan as it does not
give me anything)
[+streetDFLT:maink~2 (streetDFLT:"maine")^0.35, +cityDFLT:nasua~2
(cityDFLT:"nasuh")^0.35, ++regionDFLT:"new-hampshire"
(regionDFLT:"new-hammpshire")^0.98, ++countryDFLT:"united"
(countryDFLT:"uniten")^0.42000002 +countryDFLT:"states"
(countryDFLT:"statesir")^0.56]
explain plan gives:
Explanation expl = is.explain(booleanQuery.build(), 10);
System.out.println(expl);
This prints:
0.0 = Failure to meet condition(s) of required/prohibited clause(s)
0.0 = no match on required clause (+regionDFLT:new-hampshire
(regionDFLT:new-hammpshire)^0.98)
0.0 = Failure to meet condition(s) of required/prohibited clause(s)
0.0 = no match on required clause (regionDFLT:new-hampshire)
0.0 = no matching term
0.0 = no match on required clause (+countryDFLT:united
(countryDFLT:uniten)^0.42000002 +countryDFLT:states
(countryDFLT:statesir)^0.56)
0.0 = Failure to meet condition(s) of required/prohibited clause(s)
0.0 = no match on required clause (countryDFLT:united)
0.0 = no matching term
0.0 = no match on required clause (countryDFLT:states)
0.0 = no matching term
Best regards
On 6/26/19 12:48 PM, Atri Sharma wrote:
> It depends a lot on the actual clauses (whether they are SHOULD, MUST,
> MUST_NOT), each query’s type (phrase, term etc).
>
> Could you post your query and the explain plan of IndexSearcher post the
> rewrite?
>
> On Wed, 26 Jun 2019 at 6:46 PM, <ba...@oracle.com> wrote:
>
>> Hi,-
>>
>> how can one find out each score contribution from booleanquery
>> components?
>>
>> Best regards
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
>> For additional commands, e-mail: java-user-help@lucene.apache.org
>>
>> --
> Regards,
>
> Atri
> Apache Concerted
>
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org