From 26ed3b8ab4f4569b58ff26c7ab9d724067e6b315 Mon Sep 17 00:00:00 2001 From: chengmo Date: Mon, 20 Jan 2025 18:02:09 +0800 Subject: [PATCH] update Functioncall --- python/core/component.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/python/core/component.py b/python/core/component.py index da864415..7ef67c59 100644 --- a/python/core/component.py +++ b/python/core/component.py @@ -122,6 +122,7 @@ class FunctionCall(BaseModel, extra='allow'): thought: str = Field(default="", description="思考结果") name: str = Field(default="", description="工具名") arguments: dict = Field(default={}, description="参数列表") + component: Optional[str] = Field(default="", description="组件名class name") class Json(BaseModel, extra='allow'): @@ -129,7 +130,7 @@ class Json(BaseModel, extra='allow'): class Content(BaseModel): - name: str = Field(default="", + name: Optional[str] = Field(default="", description="介绍当前yield内容的阶段名, 使用name的必要条件,是同一组件会输出不同type的content,并且需要加以区分,方便前端渲染与用户展示") visible_scope: str = Field(default="all", description="为了界面展示明确的说明字段,三种取值:llm、user、all。llm为思考模型可见,类似function calling结果中submit的执行结果,user为终端用户可见,all包含上述两者")