Skip to content

WeChat /l:清积压只投最新 #40

Description

@tuchg

Destination

修正 WeChat /latest / /l:清除通道积压后,按 workspace 只向微信投递最新一轮 agent 通知(不是把积压全量刷出);周期限流解除后的 retry tick 整队丢弃不投;同步 docs 与测试,使行为与文案一致。

Notes

  • Domain: WeChat channel adapter 出站队列(lucarne-wechat pending_notifications),与 lucarne::history / provider 无关。
  • Skills: 实现阶段用 tdd;边界见 Agents.md Provider Responsibility(本改动仅 channel)。
  • 本 effort 允许执行(Destination 含落地),不限于纯决策。
  • 已锁定策略(chart 时 grilling):
    1. /l 只动 pending_notifications;不再 retry_completed_pending_replies。
    2. 「最新」粒度 = 每个 workspace 一条最新回合:该 workspace 队列中最后一条 text,加上其后同 workspace 的 attachments;其余 entry 丢弃。
    3. /l 投递失败(含再限流)→ 直接丢,不写回队列。
    4. 周期 retry tick:限流解除后第一次跑到时,对 pending_notifications 整队 drain 且不发送(旧积压作废;之后靠新事件或用户在丢弃前 /l)。
    5. 限流清除仍由现有 incoming /l 路径负责;无菜单回复语义保持。
  • 现状锚点: WechatNotificationService::handle_slash_command(Latest) → retry_pending_notifications() 全量 drain 发送;docs 写「冲刷积压」易被理解成全量推送。

Decisions so far

Not yet specified

(none — destination reached)

Out of scope

  • 改 Telegram 或其它 channel 的同类命令(除非日后另开 map)。
  • 重做限流算法、队列容量、MAX_PENDING_* 策略。
  • pending replies 对话回包语义(本 map 明确 /l 不再碰它;周期 path 对 replies 保持现状)。
  • UI/帮助菜单大改(仅同步 /l 文案到「清积压 + 只投最新」)。

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    wayfinder:mapWayfinder effort map (index issue)

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions