| from __future__ import annotations | |
| import os | |
| from dataclasses import dataclass | |
| class AppConfig: | |
| model_name: str = "meta/llama-3.3-70b-instruct" | |
| nvidia_env_key: str = "NVIDIA_API_KEY" | |
| base_url: str = "https://integrate.api.nvidia.com/v1" | |
| def load_environment() -> str | None: | |
| api_key = os.getenv(AppConfig.nvidia_env_key) | |
| print(f"NVIDIA API Key loaded: {'✓' if api_key else '✗'}") | |
| if not api_key: | |
| print(f"⚠️ {AppConfig.nvidia_env_key} not set in environment") | |
| return api_key | |