Config Module (config.py)
- class config.GoogleConfig(_raw_path='google_credentials.json')[исходный код]
Базовые классы:
object
Configuration for Google API access, specifically for service account credentials.
If a relative path is specified in the GOOGLE_CREDENTIALS_PATH environment variable (or if it is not set), it will be converted to an absolute path within the project directory. This avoids issues when the bot is run from any directory or on a different OS (Windows vs Linux).
- Параметры:
_raw_path (
str
)
- class config.LoggingConfig(level='WARNING', format='%(asctime)s - %(name)s - %(levelname)s - %(message)s')[исходный код]
Базовые классы:
object
Configuration for application logging.
- class config.OpenAIConfig(api_key='', model='gpt-4o-mini', max_retries=2)[исходный код]
Базовые классы:
object
Configuration for the OpenAI API client.
- class config.PrometheusConfig(port=<factory>)[исходный код]
Базовые классы:
object
Configuration for prometheus_client exporter.
- Параметры:
port (
int
)
- class config.RateLimiterConfig(llm_requests_per_minute=20, llm_max_burst=5)[исходный код]
Базовые классы:
object
Configuration for API rate limiting, specifically for LLM calls.
- class config.SchedulerConfig(timezone='Europe/Moscow', morning_time='08:00', evening_time='20:00', motivation_interval_hours=8)[исходный код]
Базовые классы:
object
Configuration for the task scheduler (APScheduler).