lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jan Høydahl (Commented) (JIRA) <j...@apache.org>
Subject [jira] [Commented] (SOLR-2649) MM ignored in edismax queries with operators
Date Thu, 02 Feb 2012 20:24:54 GMT

    [ https://issues.apache.org/jira/browse/SOLR-2649?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13199181#comment-13199181
] 

Jan Høydahl commented on SOLR-2649:
-----------------------------------

So how should the parser interpret these examples?

{noformat}
q=word1 word2 word3 -word4&mm=100%
{noformat}
I agree with Ahmet that here both word1, word2 and word3 must be required since mm is explicitly
specified. If mm is not specified, mm is set from defaultOperator, i.e. AND=>100%, OR=>0

{noformat}
q=word1 word2 word3 -word4%mm=50%
{noformat}
Here you'd expect that two of of the three first words must match.

{noformat}
q=word1 OR word2 word3%mm=100%
Example after having indexed exampledocs:
http://localhost:8983/solr/browse?q=ipod%20OR%20samsung%20printer&debugQuery=true&mm=100%25
{noformat}
With ipod OR samsung I get 5 hits. Adding the word "printer" yields 6 hits, i.e. it is OR'ed
too. Here I'd expect the equivalent of (word1 OR word2) AND word3.

{noformat}
q=word1 AND word2 word3%mm=50%
{noformat}
What would you expect for this? Perhaps (word1 AND word2) to be treated as clause1 and word3
as clause2 and then apply mm=1?

{noformat}
q=word1 OR word2 word3 word4 word5%mm=50%
{noformat}
How about this? Again, it would make sense to respect (word1 OR word2) as one clause and then
require two clauses out of the resulting four.
                
> MM ignored in edismax queries with operators
> --------------------------------------------
>
>                 Key: SOLR-2649
>                 URL: https://issues.apache.org/jira/browse/SOLR-2649
>             Project: Solr
>          Issue Type: Bug
>          Components: search
>    Affects Versions: 3.3
>            Reporter: Magnus Bergmark
>            Priority: Minor
>
> Hypothetical scenario:
>   1. User searches for "stocks oil gold" with MM set to "50%"
>   2. User adds "-stockings" to the query: "stocks oil gold -stockings"
>   3. User gets no hits since MM was ignored and all terms where AND-ed together
> The behavior seems to be intentional, although the reason why is never explained:
>   // For correct lucene queries, turn off mm processing if there
>   // were explicit operators (except for AND).
>   boolean doMinMatched = (numOR + numNOT + numPluses + numMinuses) == 0; 
> (lines 232-234 taken from tags/lucene_solr_3_3/solr/src/java/org/apache/solr/search/ExtendedDismaxQParserPlugin.java)
> This makes edismax unsuitable as an replacement to dismax; mm is one of the primary features
of dismax.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

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


Mime
View raw message