I am using Solr to search for "more like this" content. The field which mlt
should operate on has normally the length of a sentence. So I am actually
searching for mlt sentences.
I have configured a mlt request handler in the solrconfig.xml
<requestHandler name="/mlt" class="solr.MoreLikeThisHandler">
<str name="mlt.fl">content</str>
<str name="mlt.mintf">0</str>
<str name="mlt.mindf">0</str>
</requestHandler>
The corresponding schema.xml
<schema name="MyAppSchema" version="1.6">
<field name="content" type="text_mlt" indexed="true" stored="true"
required="true" />
<fieldType name="text_mlt" class="solr.TextField" termVectors="true" >
<analyzer type="index">
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.StopFilterFactory" ignoreCase="true"
words="stopwords.txt" />
<filter class="solr.LowerCaseFilterFactory"/>
</analyzer>
<analyzer type="query">
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.StopFilterFactory" ignoreCase="true"
words="stopwords.txt" />
<filter class="solr.SynonymGraphFilterFactory"
synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
<filter class="solr.LowerCaseFilterFactory"/>
</analyzer>
</fieldType>
</schema>
When I am now execute requests against this mlt RequestHandler I get results
but without the matching score. Is it possible to return the score too when
using the Request Handler?
One example in the documentation displays the score of mlt but only when using
the
SearchHandler<https://solr.apache.org/guide/8_8/morelikethis.html#search-component-query-and-response>.
Should I use the Searchhandler to get the score? Are there any drawbacks when
using the SearchHandler over the MLT Request Handler?