|
@@ -71,7 +71,10 @@ public class ViewCountRateCorrelationStrategy implements ScoreStrategy {
|
|
|
if (hisItem.isInnerAccount() && Objects.nonNull(hisItem.getViewCount())
|
|
|
&& hisItem.getViewCount() > 0 && Objects.nonNull(hisItem.getAvgViewCount())
|
|
|
&& hisItem.getAvgViewCount() > 0) {
|
|
|
- Double correlation = (hisItem.getCorrelation() + 1) / 2;
|
|
|
+ Double correlation = 0.3D;
|
|
|
+ if (hisItem.getCorrelation() > 0) {
|
|
|
+ correlation = (hisItem.getCorrelation() + 1) / 2;
|
|
|
+ }
|
|
|
maxAvgViewCount = Math.max(maxAvgViewCount, hisItem.getAvgViewCount());
|
|
|
if (hisItem.getItemIndex() == 1) {
|
|
|
showViewCountSumFirst += (hisItem.getViewCount() * correlation);
|
|
@@ -83,7 +86,7 @@ public class ViewCountRateCorrelationStrategy implements ScoreStrategy {
|
|
|
if (hisItem.getFirstViewCountRate() > 1) {
|
|
|
// 对于头条均值倍数大于1的情况,次条均值线性增加,用于debias;
|
|
|
// TODO: 对于小于1的情况,是否要减去?
|
|
|
- avgViewCountSumSecond += (hisItem.getAvgViewCount() * correlation) * (hisItem.getFirstViewCountRate() - 1);
|
|
|
+ avgViewCountSumSecond += (hisItem.getAvgViewCount() * correlation) * hisItem.getFirstViewCountRate();
|
|
|
} else {
|
|
|
avgViewCountSumSecond += (hisItem.getAvgViewCount() * correlation);
|
|
|
}
|
|
@@ -95,7 +98,7 @@ public class ViewCountRateCorrelationStrategy implements ScoreStrategy {
|
|
|
if (hisItem.getFirstViewCountRate() > 1) {
|
|
|
// 对于头条均值倍数大于1的情况,次条均值线性增加,用于debias;
|
|
|
// TODO: 对于小于1的情况,是否要减去?
|
|
|
- avgViewCountSum += (hisItem.getAvgViewCount() * correlation) * (hisItem.getFirstViewCountRate() - 1);
|
|
|
+ avgViewCountSum += (hisItem.getAvgViewCount() * correlation) * hisItem.getFirstViewCountRate();
|
|
|
} else {
|
|
|
avgViewCountSum += (hisItem.getAvgViewCount() * correlation);
|
|
|
}
|