config
Configuration loading and validation.
This module provides the create_config factory function to load PyRel configuration
from various sources (YAML config files, Snowflake config, DBT profiles, or programmatically
from Python dictionaries). The configuration is represented as a validated Pydantic model
with nested sections for connections, execution settings, data settings, compiler settings,
model settings, reasoners settings, and debug settings.
Set the RAI_CONFIG_FILE_PATH environment variable to pin an explicit config file path,
bypassing auto-discovery entirely.
Examples
Loading from a YAML config file (auto-discovered):
from relationalai.config import create_config
cfg = create_config()session = cfg.get_session() # Gets session from default connectionNotes
The classes and functions in this module are re-exported in the base
relationalai.config namespace, so you can import them directly from there
instead of from this submodule.
Functions
Functions exposed by this module.
Classes
Classes exposed by this module.
raiconfig.yaml / raiconfig.yml. config.toml. profiles.yml. raiconfig.toml.