Replies to bot messages without a ping still trigger AI generation #1

Open
opened 2026-09-16 06:28:44 +00:00 by reseam-bot · 0 comments
Member

Requested by Palm: "make it so that replies without ping shouldnt cause ai gen"
(Source: https://discord.com/channels/1495093872261599323/1495093875369447507/1549667465506717759)

Current behavior

In src/chat/triggers.rs (handle_message, gate at ~line 31):

let is_bot_reply = referenced.is_some_and(|referenced| referenced.author.id == bot_id);
if !mentions_bot(discord, message, guild_id, bot_id) && !is_bot_reply && active.is_none() {
    return Ok(());
}

Any reply to a bot message passes the gate even without mentioning the bot, so it either steers an active run or starts a brand new AI conversation. Replying to command output, mod notices, etc. without a ping kicks off a run.

Expected behavior

A reply that isn't pinged should not start AI generation. Only an actual mention (or steering an active run) should trigger it.

Notes

  • Steering replies (same author, referenced message belongs to an active run, ~line 49) currently rely on the same gate. If is_bot_reply is dropped from the gate, the steering check likely needs to run before it so steering without a ping keeps working.
  • active-based steering (reply to a message inside an active run) should probably stay ping-less as it is today.
Requested by Palm: "make it so that replies without ping shouldnt cause ai gen" (Source: https://discord.com/channels/1495093872261599323/1495093875369447507/1549667465506717759) ## Current behavior In `src/chat/triggers.rs` (`handle_message`, gate at ~line 31): ```rust let is_bot_reply = referenced.is_some_and(|referenced| referenced.author.id == bot_id); if !mentions_bot(discord, message, guild_id, bot_id) && !is_bot_reply && active.is_none() { return Ok(()); } ``` Any reply to a bot message passes the gate even without mentioning the bot, so it either steers an active run or **starts a brand new AI conversation**. Replying to command output, mod notices, etc. without a ping kicks off a run. ## Expected behavior A reply that isn't pinged should not start AI generation. Only an actual mention (or steering an active run) should trigger it. ## Notes - Steering replies (same author, referenced message belongs to an active run, ~line 49) currently rely on the same gate. If `is_bot_reply` is dropped from the gate, the steering check likely needs to run before it so steering without a ping keeps working. - `active`-based steering (reply to a message inside an active run) should probably stay ping-less as it is today.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
reseam/bot#1
No description provided.