mirror of
https://gitee.com/wanwujie/deer-flow
synced 2026-04-19 04:14:46 +08:00
@@ -47,9 +47,7 @@ def _get_env_llm_conf(llm_type: str) -> Dict[str, Any]:
|
|||||||
return conf
|
return conf
|
||||||
|
|
||||||
|
|
||||||
def _create_llm_use_conf(
|
def _create_llm_use_conf(llm_type: LLMType, conf: Dict[str, Any]) -> BaseChatModel:
|
||||||
llm_type: LLMType, conf: Dict[str, Any]
|
|
||||||
) -> BaseChatModel :
|
|
||||||
"""Create LLM instance using configuration."""
|
"""Create LLM instance using configuration."""
|
||||||
llm_type_config_keys = _get_llm_type_config_keys()
|
llm_type_config_keys = _get_llm_type_config_keys()
|
||||||
config_key = llm_type_config_keys.get(llm_type)
|
config_key = llm_type_config_keys.get(llm_type)
|
||||||
@@ -91,9 +89,9 @@ def _create_llm_use_conf(
|
|||||||
return AzureChatOpenAI(**merged_conf)
|
return AzureChatOpenAI(**merged_conf)
|
||||||
if llm_type == "reasoning":
|
if llm_type == "reasoning":
|
||||||
return ChatDeepSeek(**merged_conf)
|
return ChatDeepSeek(**merged_conf)
|
||||||
else
|
else:
|
||||||
return ChatOpenAI(**merged_conf)
|
return ChatOpenAI(**merged_conf)
|
||||||
|
|
||||||
|
|
||||||
def get_llm_by_type(
|
def get_llm_by_type(
|
||||||
llm_type: LLMType,
|
llm_type: LLMType,
|
||||||
|
|||||||
Reference in New Issue
Block a user