Files
EvoScientist/EvoScientist/channels/telegram/__init__.py
T
m4 c2743251e9 Initial commit of EvoScientist framework
Self-evolving AI scientist framework built on LangGraph/LangChain with
CLI/TUI core, FastAPI gateway, and Next.js frontend.

Co-Authored-By: Claude Opus 4 <noreply@anthropic.com>
2026-07-13 08:07:45 +08:00

20 lines
544 B
Python

from ..channel_manager import _parse_csv, register_channel
from .channel import TelegramChannel, TelegramConfig
__all__ = ["TelegramChannel", "TelegramConfig"]
def create_from_config(config) -> TelegramChannel:
allowed = _parse_csv(config.telegram_allowed_senders)
proxy = config.telegram_proxy or None
return TelegramChannel(
TelegramConfig(
bot_token=config.telegram_bot_token,
allowed_senders=allowed,
proxy=proxy,
)
)
register_channel("telegram", create_from_config)