Commit 31c67025 authored by 段英荣's avatar 段英荣

modify

parent 7543e7ec
......@@ -145,6 +145,14 @@ class TopicUtils(object):
"filter": {"bool": {
"should": same_group_user_id_term_list}},
"weight": 2
},
{
"gauss": {
"update_time": {
"scale": "1d",
"decay": 0.5
}
}
}
]
......@@ -158,12 +166,6 @@ class TopicUtils(object):
}
}
},
"gauss": {
"update_time": {
"scale": "1d",
"decay": 0.5
}
},
"score_mode": "sum",
"boost_mode": "sum",
"functions": functions_list
......@@ -254,7 +256,15 @@ class TopicUtils(object):
"filter": {"term": {
"user_id": topic_user_id}},
"weight": 1000
}
},
{
"gauss": {
"update_time": {
"scale": "1d",
"decay": 0.5
}
}
}
]
if isinstance(topic_group_id,int) and topic_group_id > 0:
functions_list.append(
......@@ -280,12 +290,6 @@ class TopicUtils(object):
}
}
},
"gauss":{
"update_time":{
"scale":"1d",
"decay":0.5
}
},
"score_mode": "sum",
"boost_mode": "sum",
"functions": functions_list
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment