Skip to content

Your lightweight open-source personal agent.

fix(telegram): add group_policy config for Telegram groups

Sense_wang43329018f788
diff --git a/nanobot/config/schema.py b/nanobot/config/schema.py
index 6b80c8180..69cf82671 100644
--- a/nanobot/config/schema.py
+++ b/nanobot/config/schema.py
@@ -31,6 +31,7 @@ class TelegramConfig(Base):
allow_from: list[str] = Field(default_factory=list) # Allowed user IDs or usernames
proxy: str | None = None # HTTP/SOCKS5 proxy URL, e.g. "http://127.0.0.1:7890" or "socks5://127.0.0.1:1080"
reply_to_message: bool = False # If true, bot replies quote the original message
+ group_policy: Literal["open", "mention"] = "open" # "open" responds to all, "mention" only when @mentioned or replied to
class FeishuConfig(Base):