Files
NexQuant/rdagent/components/coder/model_coder/conf.py
T
Xu Yang 768229427d feat: use unified pickle cacher & move llm config into a isolated config (#424)
* simplify RDAgent conf

* add unified cacher(untested)

* fix small bugs

* fix a bug

* fix a small bug in runner

* use hash_key = None to skip cache

* fix CI

* in factor execution, ignore cache when raise exception

* add file locker to avoid mp calling

* fix CI

* use function __module__ name as folder in cache
2024-10-14 17:34:09 +08:00

24 lines
567 B
Python

from pathlib import Path
from typing import Union
from pydantic_settings import BaseSettings
class ModelImplSettings(BaseSettings):
class Config:
env_prefix = "MODEL_CODER_" # Use MODEL_CODER_ as prefix for environment variables
coder_use_cache: bool = False
knowledge_base_path: Union[str, None] = None
new_knowledge_base_path: Union[str, None] = None
max_loop: int = 10
query_former_trace_limit: int = 5
query_similar_success_limit: int = 5
fail_task_trial_limit: int = 20
MODEL_IMPL_SETTINGS = ModelImplSettings()