Skip to content

[Feat] Add addressee gating for unmentioned conversation messages - #3051

Merged
daniel-lxs merged 5 commits into
developfrom
feat/judgment-participation-gating-2xvttlx857tts
Sep 22, 2026
Merged

daniel-lxs merged 5 commits into
developfrom
feat/judgment-participation-gating-2xvttlx857tts

Conversation

@roomote-roomote

@roomote-roomote roomote-roomote Bot commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

​Opened on behalf of @daniel-lxs. Follow up by mentioning @roomote-roomote, in the web UI, or in Slack.

What changed

  • Added TypeSafe Jev addressee gating for eligible unmentioned Slack, Discord, and Teams thread messages using up to 20 recent messages. The gate asks two independent questions in one request: who the reply is addressed to (Roomote, another participant, unclear) and whether it expects a response or action from its addressee. A reply routes only when Roomote is the addressee at the 0.85 starting threshold and the expects-response probability is at least 0.5, so bare acknowledgements such as "ok, thanks" after a bot answer no longer start a Fast turn.
  • Made peer conversations standard behavior: a user-owned Fast conversation on Slack or Discord admits peer discussion to the gate instead of cutting it at the peer-mention check. The slackPeerConversations deployment experiment is removed from the feature-flag registry and the Settings > Experimental toggle and hook are gone. Task threads without a Fast owner keep the explicit-mention cutoff for peer-directed messages.
  • Slack now checks that the sender is linked before fetching thread history or consulting the judgment model, matching Discord and Teams. The entry handler already dropped unlinked channel-thread replies, so behavior is unchanged; their text just never leaves the deployment.
  • Kept the Slack peer-mention cutoff in task threads silent while establishing Roomote-thread eligibility first, so linked suppressed replies remain recordable without capturing unrelated threads.
  • Preserved explicit Roomote mentions, direct messages, eligibility checks, directed follow-ups, the peer-directed reminder backstop, and inbound Slack history capture when a reply is suppressed.
  • Updated the Slack, Discord, Teams, Telegram, and personal-settings docs to describe peer conversations and the addressee gate as standard behavior, with a changeset.

Why this change was made

Unmentioned messages in peer conversations could start Fast activity even when they were addressed to another human, were ambiguous, or only acknowledged Roomote's last answer. This makes participation an addressee decision without changing deployments that have no judgment backend configured.

Impact

  • There is no feature switch. The only prerequisite is a judgment backend (Settings > Models judgment choice, or the R_JUDGMENT_MODEL override), which every other judgment caller already shares. Deployments that have one selected change behavior on merge: every eligible unmentioned thread reply on Slack, Discord, and Teams is judged before it can start work, and replies the heuristic used to route can now stay silent, at one judgment call each.
  • With a backend configured, only a confident roomote addressee that also expects a response routes; participant, unclear, acknowledgement, under-threshold, malformed, and failed results stay silent, and linked senders' suppressed replies are recorded. Unlinked senders never reach the model.
  • Without a backend, the existing heuristic routing remains in place on every provider, with peer discussion in user-owned Fast conversations now admitted to it. The stale slack_peer_conversations_experiment_enabled metadata key is ignored and can stay in place for rollback.
  • Evidence: 263 API routing, judgment, Fast entry and Discord handler tests, the web experimental-settings and deployment-experiments tests, and the feature-flags tests pass; API, feature-flags and (apart from the pre-existing untouched S3 test types) web typecheck, formatting, lint, and Knip pass. Smoke tested on a local stack with Jev via OpenRouter through the mock Slack and Discord harnesses, with the old experiment key set to false: peer-addressed messages were judged participant (0.88 to 0.98) and stayed silent but recorded; unmentioned requests to Roomote (0.98 to 1.0 on both questions) routed and got Fast replies; an acknowledgement scored roomote 0.87 but expects-response 0.08 and stayed silent; an unlinked sender's message produced no judgment call; with the backend off the heuristic path routed as before; and the Settings > Experimental page no longer shows the toggle. Teams has no harness and is covered by unit tests only.

@roomote-community

roomote-community Bot commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

No new code issues found. See task

  • apps/api/src/handlers/slack/events/message-entry.ts:223 preserves inbound history for a linked peer-addressed reply rejected by the early non-experiment filter.

Reviewed 79bd0d4

Comment thread apps/api/src/handlers/slack/events/message-entry.ts Outdated
@roomote-roomote
roomote-roomote Bot marked this pull request as ready for review September 21, 2026 16:51
daniel-lxs and others added 3 commits September 22, 2026 16:09
Slack judged an unmentioned reply before checking whether the sender was
linked, so an unlinked spectator's message reached the judgment model and
was then dropped by the entry handler. Check the mapping first, as Discord
and Teams already do, so unlinked senders never reach the history fetch or
the model.

The addressee question alone routed bare acknowledgements: "ok, thanks"
after a bot answer is addressed to Roomote, so it scored 0.95 and started
a Fast turn that ended silent. Ask a second, independent Noul question in
the same request, whether the reply expects a response, and route only when
both agree. Malformed answers to either question fail closed as before.
The addressee gate and peer-conversation admission no longer depend on the
slackPeerConversations deployment experiment. A user-owned Fast conversation
admits peer discussion on Slack and Discord, and every eligible unmentioned
thread reply on Slack, Discord, and Teams is judged whenever the deployment
has a judgment backend; without one the existing heuristics apply unchanged.

Remove the experiment from the feature-flag registry and the Settings >
Experimental toggle and hook, rename the carried flag to
peerConversationsEnabled, and update the Slack, Discord, Teams, Telegram,
and personal-settings docs to describe the behavior as standard.
@daniel-lxs
daniel-lxs merged commit f8709fb into develop Sep 22, 2026
19 checks passed
@daniel-lxs
daniel-lxs deleted the feat/judgment-participation-gating-2xvttlx857tts branch September 22, 2026 17:40
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