[
https://issues.apache.org/jira/browse/SOLR-9267?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Brian Feldman updated SOLR-9267:
--------------------------------
Description:
When boosting by field "fieldname otherFieldName^4.0" the boost is not stripped
from the field name when adding to fieldNames ArrayList. So on line 133 of
CloudMLTQParser when adding field content to the filteredDocument the field is
not found (incorrectly trying to find 'otherFieldName^4.0').
The easiest but perhaps hackiest solution is to overwrite qf:
{code}
if (localParams.get("boost") != null) {
mlt.setBoost(localParams.getBool("boost"));
boostFields = SolrPluginUtils.parseFieldBoosts(qf);
qf = boostFields.keySet().toArray(qf);
}
{code}
was:
When boosting by field "fieldname otherFieldName^4.0" the boost is not stripped
from the field name when adding to fieldNames ArrayList. So on line 133 of
CloudMLTQParser when adding field content to the filteredDocument the field is
not found (incorrectly trying to find 'otherFieldName^4.0').
The easiest but perhaps hackiest solution is to overwrite qf:
if (localParams.get("boost") != null) {
mlt.setBoost(localParams.getBool("boost"));
boostFields = SolrPluginUtils.parseFieldBoosts(qf);
qf = boostFields.keySet().toArray(qf);
}
> Cloud MLT field boost not working
> ---------------------------------
>
> Key: SOLR-9267
> URL: https://issues.apache.org/jira/browse/SOLR-9267
> Project: Solr
> Issue Type: Bug
> Security Level: Public(Default Security Level. Issues are Public)
> Components: MoreLikeThis
> Affects Versions: 5.5, 5.5.1, 5.5.2
> Reporter: Brian Feldman
>
> When boosting by field "fieldname otherFieldName^4.0" the boost is not
> stripped from the field name when adding to fieldNames ArrayList. So on line
> 133 of CloudMLTQParser when adding field content to the filteredDocument the
> field is not found (incorrectly trying to find 'otherFieldName^4.0').
> The easiest but perhaps hackiest solution is to overwrite qf:
> {code}
> if (localParams.get("boost") != null) {
> mlt.setBoost(localParams.getBool("boost"));
> boostFields = SolrPluginUtils.parseFieldBoosts(qf);
> qf = boostFields.keySet().toArray(qf);
> }
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]