...
|
...
|
@@ -83,12 +83,10 @@ public class RecallResultBuilder { |
|
|
paramMap.put("uid",""+uid);
|
|
|
PersonalizedSearch personalizedSearch = personalVectorFeatureSearch.getPersonalizedSearch(paramMap);
|
|
|
UserFeatureFactor userFeatureFactor = new UserFeatureFactor(personalizedSearch);
|
|
|
RECALL_NEW_LOGGER.info("userFeatureFactor info ,factor is[{}], version is[{}] ",userFeatureFactor.userFeatureFactors,userFeatureFactor.vectorFeatureVersion);
|
|
|
//2、计算相关性
|
|
|
for (RecallMergerResult.SknResult sknResult : sknResultList) {
|
|
|
double score = productFeatureFactorHepler.calProductFeatureFactor(userFeatureFactor, sknResult.getFactor());
|
|
|
sknResult.setScore(score);
|
|
|
RECALL_NEW_LOGGER.info("skn is [{}], factor is[{}] ,score is [{}] ",sknResult.getProductSkn(),sknResult.getFactor(),score);
|
|
|
}
|
|
|
//3、按得分排序
|
|
|
Collections.sort(sknResultList, new Comparator<RecallMergerResult.SknResult>() {
|
...
|
...
|
|