You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Syncs Hermes session titles to the platform-visible conversation name when the active platform supports it
This adds a generic BasePlatformAdapter.rename_conversation(...) capability, analogous to create_handoff_thread(...), so the gateway can request “rename the current visible conversation” without knowing whether that means a Discord thread, Telegram topic, or another platform-specific container
Discord implements this for thread channels, so both auto-generated session titles and manual /title ... updates rename the visible Discord thread instead of only updating the session database
Telegram topic title syncing is moved behind the same adapter capability while preserving the existing Telegram safety checks
Related Issue
N/A
Type of Change
🐛 Bug fix (non-breaking change that fixes an issue)
✨ New feature (non-breaking change that adds functionality)
🔒 Security fix
📝 Documentation update
✅ Tests (adding or improving test coverage)
♻️ Refactor (no behavior change)
🎯 New skill (bundled or hub)
Changes Made
Added optional BasePlatformAdapter.rename_conversation(...) capability in gateway/platforms/base.py
Updated the gateway title sync path in gateway/run.py to call the adapter capability instead of hardcoding platform-specific rename behavior
Updated /title ... handling in gateway/slash_commands.py so manual title changes also sync to supported visible conversation names
Implemented Discord conversation renaming in plugins/platforms/discord/adapter.py
Only renames thread channels
Sanitizes thread names to Discord’s 100-character limit
Uses Discord thread/channel edit(name=...)
Moved Telegram topic rename behavior into plugins/platforms/telegram/adapter.py
Skips root/general topics
Honors extra.disable_topic_auto_rename
Skips operator-declared dm_topics
Verifies the topic binding belongs to the current session before renaming
Added Discord title sync coverage in tests/gateway/test_discord_thread_title_rename.py
Updated Telegram topic title sync tests in tests/gateway/test_telegram_topic_mode.py
Updated /title command tests in tests/gateway/test_title_command.py
In a Discord auto-thread session, send a message that triggers Hermes auto-title generation and confirm the Discord thread name updates to the generated session title
This PR generalizes the base-adapter abstraction (rename_conversation(...), analogous to create_handoff_thread(...)) across BOTH Discord threads and Telegram topics, and routes both auto-title and manual /title through it — a broader cross-platform mechanism than the Discord-only or Telegram-only competitors. Reviewers picking a single canonical implementation for this long-standing cluster should compare this against #30559 and #26477.
Fixed via #60187 (salvage of #56792 by @rungmc357). Your PR had the nicest architecture of the six — the generic rename_conversation() adapter capability is the right shape for this — but it also refactored the live Telegram rename path as part of a Discord feature, which was more blast radius than we wanted in one change.
If a third platform grows rename support (Slack threads, Matrix rooms), the capability-ABC approach you sketched is exactly what we'd reach for, and we'd welcome it as its own focused refactor at that point. Thanks for the contribution!
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
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.
What does this PR do?
Syncs Hermes session titles to the platform-visible conversation name when the active platform supports it
This adds a generic
BasePlatformAdapter.rename_conversation(...)capability, analogous tocreate_handoff_thread(...), so the gateway can request “rename the current visible conversation” without knowing whether that means a Discord thread, Telegram topic, or another platform-specific containerDiscord implements this for thread channels, so both auto-generated session titles and manual
/title ...updates rename the visible Discord thread instead of only updating the session databaseTelegram topic title syncing is moved behind the same adapter capability while preserving the existing Telegram safety checks
Related Issue
N/A
Type of Change
Changes Made
BasePlatformAdapter.rename_conversation(...)capability ingateway/platforms/base.pygateway/run.pyto call the adapter capability instead of hardcoding platform-specific rename behavior/title ...handling ingateway/slash_commands.pyso manual title changes also sync to supported visible conversation namesplugins/platforms/discord/adapter.pyedit(name=...)plugins/platforms/telegram/adapter.pyextra.disable_topic_auto_renamedm_topicstests/gateway/test_discord_thread_title_rename.pytests/gateway/test_telegram_topic_mode.py/titlecommand tests intests/gateway/test_title_command.pyHow to Test
python -m pytest \ tests/gateway/test_discord_thread_title_rename.py \ tests/gateway/test_title_command.py \ tests/agent/test_title_generator.py \ tests/gateway/test_telegram_topic_mode.py \ tests/gateway/test_discord_free_response.py \ tests/e2e/test_discord_adapter.py \ -q -o 'addopts='Checklist
Code
fix(scope):,feat(scope):, etc.)pytest tests/ -qand all tests passDocumentation & Housekeeping
docs/, docstrings) — or N/Acli-config.yaml.exampleif I added/changed config keys — or N/ACONTRIBUTING.mdorAGENTS.mdif I changed architecture or workflows — or N/AFor New Skills
N/A
Screenshots / Logs
Targeted regression suite: