feat(config): log resolved llm and embedding model names on startup
Add INFO log in get_settings() to print the actual model names after merging .env and class defaults. Confirms pydantic-settings priority: env values override class defaults as expected. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
parent
a7a22f1494
commit
d444c99c23
|
|
@ -1,8 +1,11 @@
|
||||||
from functools import lru_cache
|
from functools import lru_cache
|
||||||
|
import logging
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
from pydantic_settings import BaseSettings
|
from pydantic_settings import BaseSettings
|
||||||
|
|
||||||
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
||||||
class Settings(BaseSettings):
|
class Settings(BaseSettings):
|
||||||
# LLM access
|
# LLM access
|
||||||
|
|
@ -41,4 +44,6 @@ class Settings(BaseSettings):
|
||||||
|
|
||||||
@lru_cache
|
@lru_cache
|
||||||
def get_settings() -> Settings:
|
def get_settings() -> Settings:
|
||||||
return Settings()
|
s = Settings()
|
||||||
|
logger.info("Settings loaded: llm_model=%s embedding_model=%s", s.llm_model_name, s.embedding_model)
|
||||||
|
return s
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue