Skip to content

Bug: profile Telegram gateways register only core command set instead of full skill menu #8108

@eric-x-liu

Description

@eric-x-liu

Summary

Profile-based Telegram gateways (hermes -p work gateway run, hermes -p personal gateway run) can come up connected, but only register the core Telegram command set instead of the full skill-backed command menu.

What I expected

Profile Telegram bots should register the same skill-backed slash commands as the default profile bot, subject to the normal Telegram 100-command limit and per-platform disabled-skill rules.

What happens

On fresh startup, the default bot registers the expected 100 commands, but profile bots only register the core command set (29 commands).

Reproduction

  1. Create a default Hermes workspace/profile with Telegram configured.
  2. Create a cloned profile, for example:
    • hermes profile create work --clone
    • hermes profile create personal --clone
  3. Start all three gateways:
    • hermes gateway run
    • hermes -p work gateway run
    • hermes -p personal gateway run
  4. Query Telegram Bot API getMyCommands for each bot token.

Observed results

  • Default bot: 100 commands returned by getMyCommands
  • work bot: only 29 commands returned
  • personal bot: only 29 commands returned

At the same time:

  • telegram_menu_commands(max_commands=100) run manually under the profile homes returns the full 100-command menu
  • the profile skill trees exist on disk
  • CLI skills access still works

Evidence / code path

Telegram registration happens here:

  • gateway/platforms/telegram.py
    • calls telegram_menu_commands(max_commands=100)
    • then await self._bot.set_my_commands(...)

The command builder itself is not profile-specific:

  • hermes_cli/commands.py
    • telegram_menu_commands()
    • _collect_gateway_skill_entries()

The relevant caching behavior appears here:

  • agent/skill_commands.py
    • _skill_commands is process-global
    • get_skill_commands() only rescans if the cache is empty
  • cli.py
    • eagerly calls scan_skill_commands() at import time
  • hermes_cli/profiles.py
    • already notes a similar HERMES_HOME caching issue for sync_skills() and works around it by using a subprocess

This makes it look like the profile gateway process can end up registering Telegram commands from stale/global skill-command state during startup.

Workaround that worked locally

A post-start refresh that explicitly recomputes and pushes Telegram commands for each profile resolves it.

Version

Observed on nousresearch/hermes-agent:v2026.4.8.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Medium — degraded but workaround existscomp/gatewayGateway runner, session dispatch, deliveryplatform/telegramTelegram bot adaptertool/skillsSkills system (list, view, manage)type/bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions