Skip to content

Let Feishu group Agents listen without noisy replies - #996

Draft
Y1fe1Zh0u wants to merge 1 commit into
dataelement:v1.11.4from
Y1fe1Zh0u:agent/feishu-passive-listening-v1114
Draft

Let Feishu group Agents listen without noisy replies#996
Y1fe1Zh0u wants to merge 1 commit into
dataelement:v1.11.4from
Y1fe1Zh0u:agent/feishu-passive-listening-v1114

Conversation

@Y1fe1Zh0u

Copy link
Copy Markdown
Collaborator

What changed

  • Receive ordinary Feishu group messages with provider-message idempotency and sender identity.
  • Run external groups on stable Session threads with immutable message cutoffs and rolling Session Context compaction.
  • Suppress exact token-only NO_REPLY completions before creating a Feishu outbox.
  • Require direct-addressed messages to receive visible replies.
  • Keep normal replies bound to the input Session; unconfirmed cross-Session send_channel_message calls are rejected.
  • Add im:message.group_msg to the Basic and Full permission JSON templates.

Why

The prior integration only received group @ events. After enabling full group-message permission, every message would have produced a visible reply, external group Runs lacked a complete scheduling/cutoff contract, and the model could guess a different group through send_channel_message instead of relying on the Runtime-bound origin target.

Impact

Feishu bots can passively observe group conversations, answer direct requests, remain silent when irrelevant, preserve bounded group context, and reliably return normal replies to the originating group. Existing Feishu applications still require manual permission approval and version publication for im:message.group_msg.

Validation

  • Clean v1.11.4 branch focused backend suite: 162 passed.
  • Earlier focused backend suites: 113, 90, 66, and 61 passed.
  • Frontend npm run build passed.
  • scripts/arch-guard.sh passed with existing baseline warnings.
  • Live 3010 E2E: ordinary non-@ group input, sender IDs, exact NO_REPLY suppression, origin-Session delivery, cross-Session guard, and calendar creation/delivery.

Deployment note

The feature is already narrowly deployed and live-validated on 3010. The repository working tree retains unrelated user-owned documentation changes that are not included in this PR.

Feishu group bots can now accept ordinary user messages, freeze each input on a stable external-group lane, retain provider sender identity, and suppress exact NO_REPLY completions before creating an external outbox. Current-conversation replies stay bound to the originating Session, while explicit cross-Session sends require an execution-time confirmation flag.

Constraint: Existing Feishu apps require manual im:message.group_msg approval and publication.

Rejected: Let models choose a reply group through send_channel_message | directory guesses can send to the wrong Session.

Confidence: high

Scope-risk: moderate

Directive: Keep ordinary replies on the Run delivery target; cross-Session channel sends must remain explicit and validated.

Tested: Backend focused pytest suites (113, 90, 66, and 61 passed); scoped Ruff on modified focused files; frontend npm run build; scripts/arch-guard.sh; live 3010 Feishu ordinary-message, NO_REPLY, origin-Session delivery, and calendar E2E.

Not-tested: Multi-worker load and high-volume long-running compaction under production traffic.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant