Repository navigation
feat(feishu): bot-to-bot with post+at, require_mention loop guard, manual MAP config - #51269
Closed
crayfish-ai wants to merge 4 commits into
Closed
crayfish-ai wants to merge 4 commits into
crayfish-ai wants to merge 4 commits into
Conversation
crayfish-ai
force-pushed
the
feat/feishu-bot-to-bot
branch
4 times, most recently
from
June 25, 2026 14:39
cf8e836 to
5946d92
Compare
crayfish-ai
force-pushed
the
feat/feishu-bot-to-bot
branch
from
June 26, 2026 02:53
fabf2c1 to
00fdb33
Compare
crayfish-ai
force-pushed
the
feat/feishu-bot-to-bot
branch
from
June 26, 2026 02:54
00fdb33 to
e1c6bd3
Compare
- fix(gateway): clear stale resume_pending markers in scheduler - fix(hermes_state): add active column to message INSERT (NousResearch#51646) - feat(feishu): restore bot-to-bot mention support (FEISHU_BOT_MENTION_MAP)
…state): explicit active=1 in INSERT - hermes_state.py: add active column to add_message INSERT (NousResearch#51646) - hindsight/__init__.py: check auto_recall before claiming memory injected (NousResearch#52153) - tests: add auto_recall=false test case for hindsight
…-bot review follow-up) - Remove dead register_p2_im_chat_member_bot_added_v1 mock - Update tests for reply→create API change - Update bot name resolution tests from batch_bots→contact.v3.user.get - Change allow_bots default from 'none' to 'all' - Fix _resolve_sender_profile test for new contact.v3.user.get API
crayfish-ai
force-pushed
the
feat/feishu-bot-to-bot
branch
from
June 26, 2026 09:36
e1c6bd3 to
65fc26f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Hermes bots in Feishu group chats cannot interact with each other. Messages from bots are ignored, and there's no way for a bot to @mention another bot and have it actually receive a mention event.
Solution
Enables bot-to-bot communication in Feishu group chats through these mechanisms:
post+at outbound messages — Converts text
@bot_nameinto Feishu post format withattags, which triggers real mention events that other bots can receive.require_mention loop guard — In group chats, non-bot messages require @mention to pass admission. Bot messages (
is_bot=True) are exempt whenallow_bots="all", allowing unknown bots to be discovered without pre-configuration.Bot name persistence — Maps bot names to open_ids via
FEISHU_BOT_MENTION_MAPenv var (seed config) + JSON file cache (runtime persistence). Unknown bots encountered at runtime are captured by their open_id and survive gateway restarts, avoiding repeated "unknown bot" treatment.Group reply routing — Group replies skip
message.reply(which lands in topic threads invisible to other members) and always usemessage.createto the main chat.Design Notes
contact.v3.user.getAPI (unified user/bot query within app contact scope) instead ofbot/basic_batchwhich required elevated permissions.Changes
adapter.pytest_feishu.pytest_feishu_bot_admission.py10 commits. All 265 feishu tests pass.