完善成员画像定时任务的周月摘要补偿策略
This commit is contained in:
@@ -127,8 +127,12 @@ class MemberContextPlugin(MessagePluginInterface):
|
||||
|
||||
# 兼容“指定群执行”的场景;若未指定则沿用全量刷新逻辑。
|
||||
target_groups = [str(g).strip() for g in (context.get("target_groups") or []) if str(g).strip()]
|
||||
enable_weekly = action_key == "weekly_refresh"
|
||||
enable_monthly = action_key == "monthly_refresh"
|
||||
# 调度层补偿策略:
|
||||
# 1. 周任务除了补周摘要,也顺手检查月摘要缺口;
|
||||
# 2. 月任务先补齐缺失周摘要,再继续补月摘要,避免“月摘要依赖周摘要但周摘要没补上”;
|
||||
# 3. 日任务仍保持轻量,不主动放大到全量周/月补偿。
|
||||
enable_weekly = action_key in {"weekly_refresh", "monthly_refresh"}
|
||||
enable_monthly = action_key in {"weekly_refresh", "monthly_refresh"}
|
||||
|
||||
try:
|
||||
if target_groups:
|
||||
|
||||
Reference in New Issue
Block a user