How kishore-iiitk/f1-iceman-bot works
F1 Iceman Bot delivers database-backed Formula 1 screens and race notifications through Telegram; a separate scheduled pipeline refreshes the data. The graph follows the documented handler-to-service-to-repository read path and the pipeline’s fetch/transform/load path, keeping orchestration with the code that invokes it. Major README capabilities are represented, including weather, news, results, reminders, status, and optional Airflow scheduling. Some feature modules were not excerpted, so their internal call relationships are shown only where the README or source index supports them.
Main entry points: services Bot services · main.py Bot application · jobs.py Sync scheduler · jobs Bot timers
Components 24
Telegram interface
- Bot application
main.py - Race screens
bot/handlers - Drivers and standings
bot/handlers - News screen
bot/handlers/news.py - Reminder settings
bot/handlers/notifications.py - Status screen
bot/handlers/status.py - Messages and keyboards
bot/constants/messages.py
Bot data access
- Bot services
bot/services - SQL repositories
bot/repository - Connection pool
bot/db/connection.py
Data pipeline
- Sync scheduler
pipeline/jobs.py - Source clients
pipeline/jolpica.py - Weather client
pipeline/openmeteo.py - RSS client
pipeline/news.py - HTTP support
pipeline/http.py - Payload transforms
pipeline/transform.py - Database loader
pipeline/load.py
Scheduling and delivery
- Bot timers
bot/jobs - Subscriber delivery
bot/jobs/delivery.py
Other components
- Telegram user
- PostgreSQL
- F1, weather, RSS
- Telegram service
- Airflow scheduler
Connections 34
- Telegram user → Bot application: sends updates
main.py - Bot application → Race screens: registers routes
main.py - Bot application → Drivers and standings: registers routes
main.py - Bot application → News screen: registers route
main.py - Bot application → Reminder settings: registers route
main.py - Bot application → Status screen: registers command
main.py - Race screens → Bot services: requests data
bot/handlers/next_race.py - Drivers and standings → Bot services: requests data
bot/handlers/drivers.py - News screen → Bot services: requests headlines
bot/handlers/news.py - Reminder settings → Bot services: updates preferences
bot/handlers/notifications.py - Status screen → Bot services: requests status
bot/handlers/status.py - Race screens → Messages and keyboards: formats responses
bot/constants/messages.py - Drivers and standings → Messages and keyboards: formats responses
bot/constants/messages.py - Bot services → SQL repositories: delegates queries
bot/services/driver_service.py - SQL repositories → Connection pool: gets connections
bot/repository/driver_repository.py - Connection pool → PostgreSQL: opens connections
bot/db/connection.py - Sync scheduler → Source clients: fetches F1 data
pipeline/jobs.py - Sync scheduler → Weather client: fetches forecasts
pipeline/jobs.py - Sync scheduler → RSS client: fetches headlines
pipeline/jobs.py - Source clients → HTTP support: uses HTTP support
pipeline/jolpica.py - Source clients → F1, weather, RSS: requests F1 data
- Weather client → F1, weather, RSS: requests forecasts
- RSS client → F1, weather, RSS: reads RSS feeds
- Sync scheduler → Payload transforms: transforms payloads
pipeline/jobs.py - Sync scheduler → Database loader: loads rows
pipeline/jobs.py - Database loader → PostgreSQL: writes data
README.md - Bot application → Bot timers: schedules timers
main.py - Bot timers → Sync scheduler: runs due syncs
bot/jobs/sync.py - Bot timers → Bot services: claims reminders
bot/jobs/reminders.py - Bot timers → Bot services: claims results
bot/jobs/results.py - Bot timers → Subscriber delivery: sends broadcasts
bot/jobs/results.py - Subscriber delivery → Bot services: loads subscribers
bot/jobs/delivery.py - Subscriber delivery → Telegram service: sends messages
bot/jobs/delivery.py - Airflow scheduler → Sync scheduler: runs pipeline
README.md