简体   繁体   English

基于数组搜索的Solr MultiValued得分提升

[英]Solr MultiValued scoring boost with search based on array

First, I'm fairly new to solr and I'm far from sure that solr is the right solution to solve this problem. 首先,我对solr很新,我很难确定solr是解决这个问题的正确解决方案。 The documents that I'm working on is already there so, if solr can solve it, then it would be great :) 我正在处理的文件已经存在,如果solr可以解决它,那就太棒了:)

One of our fields in a document is of type string and have attribute multiValued set to true. 文档中的一个字段是string类型,并且属性multiValued设置为true。 It contains a list of id's that the current document relates to. 它包含当前文档所涉​​及的id列表。

The task a head now is that I know have a second list of id's (same domain) and, if any of these id's matches (if more then one id matches then I want a higher score), then I would like to boost the score of the document. 现在的任务是我知道有第二个id的列表(相同的域名),如果这些id匹配中的任何一个(如果多于一个id匹配然后我想要更高的分数),那么我想提高分数该文件。

Use Boost Query if you are using dismax or edismax. 如果您使用的是dismax或edismax,请使用Boost Query

For example, bq=id:1 OR id:2 OR id3 will boost documents which have at least one of the 3 ids. 例如, bq=id:1 OR id:2 OR id3将提升具有3个ID中的至少一个的文档。 It will also give a higher boost to documents with more matching ids. 它还将为具有更多匹配ID的文档提供更高的提升。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM