Commit 17cd5122 authored by Yeuoly's avatar Yeuoly Committed by takatost

fix: bugs

parent 97398ff2
...@@ -52,7 +52,7 @@ class AgentChatAppConfigManager(BaseAppConfigManager): ...@@ -52,7 +52,7 @@ class AgentChatAppConfigManager(BaseAppConfigManager):
else: else:
config_from = EasyUIBasedAppModelConfigFrom.APP_LATEST_CONFIG config_from = EasyUIBasedAppModelConfigFrom.APP_LATEST_CONFIG
if override_config_dict != EasyUIBasedAppModelConfigFrom.ARGS: if config_from != EasyUIBasedAppModelConfigFrom.ARGS:
app_model_config_dict = app_model_config.to_dict() app_model_config_dict = app_model_config.to_dict()
config_dict = app_model_config_dict.copy() config_dict = app_model_config_dict.copy()
else: else:
......
...@@ -37,7 +37,7 @@ class CompletionAppConfigManager(BaseAppConfigManager): ...@@ -37,7 +37,7 @@ class CompletionAppConfigManager(BaseAppConfigManager):
else: else:
config_from = EasyUIBasedAppModelConfigFrom.APP_LATEST_CONFIG config_from = EasyUIBasedAppModelConfigFrom.APP_LATEST_CONFIG
if override_config_dict != EasyUIBasedAppModelConfigFrom.ARGS: if config_from != EasyUIBasedAppModelConfigFrom.ARGS:
app_model_config_dict = app_model_config.to_dict() app_model_config_dict = app_model_config.to_dict()
config_dict = app_model_config_dict.copy() config_dict = app_model_config_dict.copy()
else: else:
......
...@@ -30,16 +30,16 @@ class CompletionService: ...@@ -30,16 +30,16 @@ class CompletionService:
invoke_from=invoke_from, invoke_from=invoke_from,
stream=streaming stream=streaming
) )
elif app_model.mode == AppMode.CHAT.value: elif app_model.mode == AppMode.AGENT_CHAT.value or app_model.is_agent:
return ChatAppGenerator().generate( return AgentChatAppGenerator().generate(
app_model=app_model, app_model=app_model,
user=user, user=user,
args=args, args=args,
invoke_from=invoke_from, invoke_from=invoke_from,
stream=streaming stream=streaming
) )
elif app_model.mode == AppMode.AGENT_CHAT.value: elif app_model.mode == AppMode.CHAT.value:
return AgentChatAppGenerator().generate( return ChatAppGenerator().generate(
app_model=app_model, app_model=app_model,
user=user, user=user,
args=args, args=args,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment