From 43dad177ab6d684f0d453bae18fe32b44c45b785 Mon Sep 17 00:00:00 2001 From: goulustis Date: Thu, 12 Feb 2026 14:34:58 +0800 Subject: [PATCH] remove KeyConfig with LLMConfig --- lang_agent/config/core_config.py | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/lang_agent/config/core_config.py b/lang_agent/config/core_config.py index 3bb3d67..f60944a 100644 --- a/lang_agent/config/core_config.py +++ b/lang_agent/config/core_config.py @@ -125,11 +125,17 @@ class InstantiateConfig(PrintableConfig): def get_name(self): return self.__class__.__name__ - - @dataclass -class KeyConfig(InstantiateConfig): +class LLMKeyConfig(InstantiateConfig): + llm_name: str = "qwen-plus" + """name of llm""" + + llm_provider:str = "openai" + """provider of the llm""" + + base_url:str = "https://dashscope.aliyuncs.com/compatible-mode/v1" + """base url; could be used to overwrite the baseurl in llm provider""" api_key:str = None """api key for llm""" @@ -143,18 +149,6 @@ class KeyConfig(InstantiateConfig): logger.info("ALI_API_KEY loaded from environ") -@dataclass -class LLMKeyConfig(KeyConfig): - llm_name: str = "qwen-plus" - """name of llm""" - - llm_provider:str = "openai" - """provider of the llm""" - - base_url:str = "https://dashscope.aliyuncs.com/compatible-mode/v1" - """base url; could be used to overwrite the baseurl in llm provider""" - - @dataclass class ToolConfig(InstantiateConfig): use_tool:bool = True