fix new news
@@ -175,7 +175,7 @@ class RuleBasedSelector:
).get("detected", False) or (
prev_bot_uttr.get("active_skill", "") == "weather_skill" and weather_city_slot_requested
)
- about_news = (news_cobot_topics & cobot_topics)
+ about_news = (news_cobot_topics & cobot_topics) or ("news" in reply)
if "/new_persona" in dialog["utterances"][-1]["text"]:
# process /new_persona command
@@ -187,7 +187,7 @@ class RuleBasedSelector:
# process user utterance with sensitive content
skills_for_uttr.append("program_y_dangerous")
skills_for_uttr.append("cobotqa")
- if about_news or ("news" in reply):
+ if about_news:
skills_for_uttr.append("news_skill")
else:
# process regular utterances
@@ -232,7 +232,7 @@ class RuleBasedSelector:
if about_sports and len(dialog["utterances"]) > 2:
skills_for_uttr.append("sport_tfidf_retrieval")
- if about_news or ("news" in reply) or ("new" in reply):
+ if about_news:
skills_for_uttr.append("news_skill")
for hyp in prev_user_uttr_hyp:
