Brian created SOLR-6317:
---------------------------

             Summary: MoreLikeThis should allow more flexible query building
                 Key: SOLR-6317
                 URL: https://issues.apache.org/jira/browse/SOLR-6317
             Project: Solr
          Issue Type: Improvement
          Components: MoreLikeThis
    Affects Versions: 4.8.1
            Reporter: Brian
            Priority: Minor


It would be better if MoreLikeThis had more flexible query-building options.  
There are two main abilities that would be helpful:

1. Allowing a DisjunctionMax query to be built instead of the plain 
BooleanQuery.  

2. Applying the interesting terms to all specified query fields, instead of 
just the field it happened to be found in.

#1 is important because we generally find disjunction max to work better than 
plain boolean queries (adding the field scores together).

At the very least, the MoreLikeThis class should be made extendable, so that we 
can easily add this capability with a custom plugin, without having to rewrite 
all of the class.

I.e., at its most basic, this could be resolved by making both "createQuery" 
methods "protected" instead of "private" so that we could then just override 
this method if we wanted to implement different ways of building the query, 
without changing anything else.

At the other extreme, potentially the more complex resolution, it might be nice 
to be able to specify a search handler to use and then MoreLikeThis would 
create the query from that search handler.  For example, fi the search handler 
used the eDisMax parser and specified a number of "qf", "pf", and boosts, then 
all those would be used to construct the mlt query, using the interesting terms 
generated.




--
This message was sent by Atlassian JIRA
(v6.2#6252)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to