Files
gyandoot-v2/crates/gyandoot-core/src/lib.rs
Tara Menon a694757b6f feat(gateway): full Telegram+Discord integration with agent loop
Complete multi-platform gateway wiring:

config:
- [platform.telegram] section with bot_token
- [platform.discord] section with bot_token + guild_id
- Threaded through GyandootConfig → AgentConfig via typed structs

gateway:
- GatewayRunner::new(platforms) takes Vec<Box<dyn Platform>>
- start() spawns all platform pollers, merges receivers
- serve(agent) runs full message loop: receive → access control →
  typing indicator → session_turn() → platform.send()
- Ctrl+C graceful shutdown via tokio::select!

cmd_serve now:
1. Loads config, creates agent
2. Builds Telegram + Discord adapters from config
3. Starts gateway pollers
4. Enters serve loop until Ctrl+C
2026-06-12 16:52:28 +05:30

21 lines
844 B
Rust

//! GyanDoot Core — Shared types, configuration, and error types for the platform.
//!
//! This crate provides the foundational types used across all other GyanDoot
//! crates: agent identifiers, message types, configuration structures, and
//! a unified error hierarchy.
pub mod types;
pub mod config;
pub mod error;
pub mod service;
pub use config::{
AgentConfig, AgentSection, AnthropicConfig, BrowserSection, ConfigLoader,
DiscordPlatformCfg, GatewaySection, GyandootConfig, IdentitySection,
KanbanRootConfig, MemoryRootConfig, MemorySection, OllamaConfig,
OpenAIConfig, PlatformRootConfig, PlatformSection, ProviderRootConfig,
ProvidersSection, SecurityRootConfig, SkillsRootConfig, TelegramConfig,
TelegramPlatformCfg, WebhookConfig, DiscordConfig, load_config_from_file,
};
pub use error::*;
pub use types::*;