File size: 372 Bytes
9ff5556
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
"""Config class for handling env variables.
"""
from functools import lru_cache
from pydantic import BaseSettings

class Settings(BaseSettings):
    APP_ID: str
    USER_ID: str
    MODEL_ID: str
    CLARIFAI_PAT: str
    MODEL_VERSION_ID: str
    
    class Config:
        env_file = '.env'

@lru_cache()
def get_settings():
    return Settings()
config = get_settings()