UNPKG

tenyun

Version:

Promise based and chained Tencent Cloud OpenAPI client for NodeJS

2,290 lines (2,153 loc) 154 kB
/// <reference types="node" /> import { AxiosPromise, AxiosRequestConfig } from "axios"; /** 智能通话 */ declare interface AICallConfig { /** 启用语音互动功能 */ EnableVoiceInteract?: boolean | null; /** 启用语音通话 */ EnableVoiceCall?: boolean | null; /** 启用数智人 */ EnableDigitalHuman?: boolean | null; /** 音色配置 */ Voice?: VoiceConfig | null; /** 数智人配置 */ DigitalHuman?: DigitalHumanConfig | null; } /** Agent 的定义 */ declare interface Agent { /** AgentID */ AgentId?: string; /** WorkflowID,非空则当前Agent从workflow转换而来 */ WorkflowId?: string; /** Agent名称,同一个应用内,Agent名称不能重复 */ Name?: string; /** 插件图标url */ IconUrl?: string; /** Agent指令;当该Agent被调用时,将作为“系统提示词”使用,描述Agent应执行的操作和响应方式 */ Instructions?: string; /** 当Agent作为转交目标时的描述,用于让其他Agent的LLM理解其功能和转交时机 */ HandoffDescription?: string; /** Agent可转交的子AgentId列表 */ Handoffs?: string[]; /** Agent调用LLM时使用的模型配置 */ Model?: AgentModelInfo; /** Agent可使用的工具列表 */ Tools?: AgentToolInfo[]; /** Agent可使用的插件列表 */ Plugins?: AgentPluginInfo[]; /** 当前Agent是否是启动Agent */ IsStartingAgent?: boolean; /** Agent类型; 0: 未指定类型; 1: 知识库检索Agent */ AgentType?: number; /** 0 自由转交,1 计划与执行 */ AgentMode?: number; } /** Agent调试信息 */ declare interface AgentDebugInfo { /** 工具、大模型的输入信息,json */ Input?: string | null; /** 工具、大模型的输出信息,json */ Output?: string | null; /** 模型名 */ ModelName?: string; } /** Agent输入值,支持直接赋值和引用 */ declare interface AgentInput { /** 输入来源类型:0 用户输入,3 自定义变量(API参数) */ InputType?: number; /** 用户手写输入 */ UserInputValue?: AgentInputUserInputValue; /** 自定义变量(API参数) */ CustomVarId?: string; /** 环境变量参数 */ EnvVarId?: string; /** 应用变量参数 */ AppVarId?: string; /** 系统参数 */ SystemVariable?: AgentInputSystemVariable; } /** 系统参数 */ declare interface AgentInputSystemVariable { /** 系统参数名 */ Name?: string; /** 对话历史轮数的配置;如果Input是系统变量中的“对话历史”时才使用; */ DialogHistoryLimit?: number; } /** 用户手写输入 */ declare interface AgentInputUserInputValue { /** 用户输入的值 */ Values?: string[]; } /** Agent 知识库检索插件支持多知识库搜索 */ declare interface AgentKnowledge { /** 知识库id */ KnowledgeBizId?: string; /** 0-应用内知识库1-共享知识库 */ KnowledgeType?: number; /** 0-全部知识1-按文档和问答2-按标签 */ Filter?: number; /** 文档id */ DocBizIds?: string[]; /** true:包含所有问答false:不包含问答 */ AllQa?: boolean; /** 文档标签过滤器 */ Tag?: AgentKnowledgeFilterTag; } /** 标签过滤器 */ declare interface AgentKnowledgeAttrLabel { /** 属性ID */ AttributeBizId?: string; /** 标签值,标签值之间是或的关系,只有匹配的,才会进行知识检索,否则报检索不到 */ Inputs?: AgentInput[]; } /** 知识检索筛选范围 */ declare interface AgentKnowledgeFilter { /** 知识检索筛选方式; 0: 全部知识; 1:按文档和问答; 2: 按标签 */ FilterType?: number; /** 文档和问答过滤器 */ DocAndAnswer?: AgentKnowledgeFilterDocAndAnswer; /** 标签过滤器 */ Tag?: AgentKnowledgeFilterTag; /** 知识库列表 */ KnowledgeList?: AgentKnowledge[]; /** 是否检索全部知识 */ AllKnowledge?: boolean; } /** 文档和问答过滤器 */ declare interface AgentKnowledgeFilterDocAndAnswer { /** 文档ID列表 */ DocBizIds?: string[]; /** 问答 */ AllQa?: boolean; } /** 标签过滤器 */ declare interface AgentKnowledgeFilterTag { /** 标签之间的关系;0:AND, 1:OR */ Operator?: number; /** 标签 */ Labels?: AgentKnowledgeAttrLabel[]; } /** 知识库问答插件 */ declare interface AgentKnowledgeQAPlugin { /** 知识检索筛选范围 */ Filter?: AgentKnowledgeFilter; } /** mcp的服务信息 */ declare interface AgentMCPServerInfo { /** mcp server URL地址 */ McpServerUrl?: string; /** mcp server header信息 */ Headers?: AgentPluginHeader[]; /** 超时时间,单位秒 */ Timeout?: number; /** sse服务超时时间,单位秒 */ SseReadTimeout?: number; /** mcp server query信息 */ Query?: AgentPluginQuery[]; } /** Agent 配置里面的模型定义 */ declare interface AgentModelInfo { /** 模型名称 */ ModelName?: string; /** 模型别名 */ ModelAliasName?: string; /** 模型温度 */ Temperature?: number; /** 模型TopP */ TopP?: number; /** 模型是否可用 */ IsEnabled?: boolean; /** 对话历史条数限制 */ HistoryLimit?: number; /** 模型上下文长度字符限制 */ ModelContextWordsLimit?: string; /** 指令长度字符限制 */ InstructionsWordsLimit?: number; /** 单次会话最大推理轮数 */ MaxReasoningRound?: number; /** 模型参数 */ ModelParams?: ModelParams; } /** 应用配置MCP插件header信息 */ declare interface AgentPluginHeader { /** 参数名称 */ ParamName?: string; /** 参数值 */ ParamValue?: string; /** header参数配置是否隐藏不可见 */ GlobalHidden?: boolean; /** 输入的值 */ Input?: AgentInput; /** 参数是否可以为空 */ IsRequired?: boolean; } /** Agent 的插件信息 */ declare interface AgentPluginInfo { /** 插件id */ PluginId?: string; /** 应用配置的插件header信息 */ Headers?: AgentPluginHeader[]; /** 插件调用LLM时使用的模型配置,一般用于指定知识库问答插件的生成模型 */ Model?: AgentModelInfo; /** 插件信息类型; 0: 未指定类型; 1: 知识库问答插件 */ PluginInfoType?: number; /** 知识库问答插件配置 */ KnowledgeQa?: AgentKnowledgeQAPlugin; /** 是否使用一键授权 */ EnableRoleAuth?: boolean; /** 应用配置的插件query信息 */ Query?: AgentPluginQuery[]; /** MCP类型 */ McpType?: number; } /** 应用配置MCP插件query信息 */ declare interface AgentPluginQuery { /** 参数名称 */ ParamName?: string; /** 参数值 */ ParamValue?: string; /** query参数配置是否隐藏不可见,true-隐藏不可见,false-可见 */ GlobalHidden?: boolean; /** 参数是否可以为空 */ IsRequired?: boolean; /** 输入的值 */ Input?: AgentInput; } /** 思考事件过程信息 */ declare interface AgentProcedure { /** 索引 */ Index?: number | null; /** 执行过程英语名 */ Name?: string | null; /** 中文名, 用于展示 */ Title?: string | null; /** 状态常量: 使用中: processing, 成功: success, 失败: failed */ Status?: string | null; /** 图标 */ Icon?: string | null; /** Agent调试信息 */ Debugging?: AgentProcedureDebugging | null; /** 是否切换Agent,取值为"main"或者"workflow",不切换为空 */ Switch?: string | null; /** 工作流名称 */ WorkflowName?: string | null; /** 当前请求执行时间, 单位 ms */ Elapsed?: number | null; /** 工作流节点名称 */ NodeName?: string | null; /** 用于展示思考放在哪个回复气泡中 */ ReplyIndex?: number | null; /** 主agent */ SourceAgentName?: string | null; /** 挂号agent */ TargetAgentName?: string | null; /** Agent的图标 */ AgentIcon?: string | null; } /** Agent思考过程调试信息 */ declare interface AgentProcedureDebugging { /** 模型思考内容 */ Content?: string | null; /** 展示的具体文本内容 */ DisplayContent?: string | null; /** 1:搜索引擎参考来源;2:知识库参考来源 */ DisplayType?: number | null; /** 搜索引擎展示的索引 */ QuoteInfos?: QuoteInfo[] | null; /** 具体的参考来源 */ References?: AgentReference[] | null; /** 展示正在执行的状态 */ DisplayStatus?: string | null; /** 云桌面的URL地址 */ SandboxUrl?: string | null; /** 云桌面里面通过浏览器打开的URL地址 */ DisplayUrl?: string | null; } /** Agent中的参考来源 */ declare interface AgentReference { /** 来源文档ID */ DocId?: string | null; /** id */ Id?: string | null; /** 名称 */ Name?: string | null; /** 类型 */ Type?: number | null; /** 链接 */ Url?: string | null; /** 文档业务ID */ DocBizId?: string | null; /** 文档名称 */ DocName?: string | null; /** 问答业务ID */ QaBizId?: string | null; /** 搜索引擎索引 */ Index?: number | null; /** 标题 */ Title?: string | null; /** 知识库名称 */ KnowledgeName?: string | null; /** 知识库标识 */ KnowledgeBizId?: string | null; } /** Agent的思考过程 */ declare interface AgentThought { /** 会话 ID */ SessionId?: string | null; /** 请求 ID */ RequestId?: string | null; /** 对应哪条会话, 会话 ID, 用于回答的消息存储使用, 可提前生成, 保存消息时使用 */ RecordId?: string | null; /** 当前请求执行时间, 单位 ms */ Elapsed?: number | null; /** 当前是否为工作流 */ IsWorkflow?: boolean | null; /** 如果当前是工作流,工作流名称 */ WorkflowName?: string | null; /** 具体思考过程详情 */ Procedures?: AgentProcedure[] | null; /** TraceId */ TraceId?: string | null; /** 文件信息 */ Files?: FileInfo[] | null; } /** Agent的工具信息 */ declare interface AgentToolInfo { /** 插件id */ PluginId?: string; /** 插件名称 */ PluginName?: string; /** 插件图标url */ IconUrl?: string; /** 0 自定义插件1 官方插件2 第三方插件 目前用于第三方实现的mcp server */ PluginType?: number; /** 工具id */ ToolId?: string; /** 工具名称 */ ToolName?: string; /** 工具描述 */ ToolDesc?: string; /** 输入参数 */ Inputs?: AgentToolReqParam[]; /** 输出参数 */ Outputs?: AgentToolRspParam[]; /** 创建方式,0:服务创建,1:代码创建,2:MCP创建 */ CreateType?: number; /** MCP插件的配置信息 */ McpServer?: AgentMCPServerInfo; /** 该工具是否和知识库绑定 */ IsBindingKnowledge?: boolean; /** 插件状态,1:可用,2:不可用 */ Status?: number; /** header信息 */ Headers?: AgentPluginHeader[]; /** NON_STREAMING: 非流式 STREAMIN: 流式 */ CallingMethod?: string | null; /** query信息 */ Query?: AgentPluginQuery[]; /** 工具计费状态 0-不计费 1-可用 2-不可用(欠费、无资源等) */ FinanceStatus?: number; } /** Agent工具的请求参数定义 */ declare interface AgentToolReqParam { /** 参数名称 */ Name?: string; /** 参数描述 */ Desc?: string; /** 参数类型,0:string, 1:int, 2:float,3:bool 4:object 5:array_string, 6:array_int, 7:array_float, 8:array_bool, 9:array_object */ Type?: number; /** 参数是否必填 */ IsRequired?: boolean; /** 参数默认值 */ DefaultValue?: string; /** 子参数,ParamType 是OBJECT 或 ARRAY<>类型有用 */ SubParams?: AgentToolReqParam[]; /** 是否隐藏不可见 */ GlobalHidden?: boolean; /** agent模式下模型是否可见 */ AgentHidden?: boolean; /** 其中任意 */ AnyOf?: AgentToolReqParam[]; /** 其中一个 */ OneOf?: AgentToolReqParam[]; /** 输入 */ Input?: AgentInput; } /** Agent工具的响应参数定义 */ declare interface AgentToolRspParam { /** 参数名称 */ Name?: string; /** 参数描述 */ Desc?: string; /** 参数类型,0:string, 1:int, 2:float,3:bool 4:object 5:array_string, 6:array_int, 7:array_float, 8:array_bool, 9:array_object */ Type?: number; /** 子参数,ParamType 是OBJECT 或 ARRAY<>类型有用 */ SubParams?: AgentToolRspParam[]; /** agent模式下模型是否可见 */ AgentHidden?: boolean; /** 是否隐藏不可见 */ GlobalHidden?: boolean; /** COVER: 覆盖解析 INCREMENT:增量解析 */ AnalysisMethod?: string; } /** 自定义变量和标签关系数据 */ declare interface ApiVarAttrInfo { /** 自定义变量id */ ApiVarId?: string | null; /** 标签id */ AttrBizId?: string | null; } /** 应用基础信息 */ declare interface AppBaseInfo { /** 应用ID */ AppBizId?: string; /** 应用名称 */ AppName?: string | null; } /** 应用配置 */ declare interface AppConfig { /** 知识问答管理应用配置 */ KnowledgeQa?: KnowledgeQaConfig | null; /** 知识摘要应用配置 */ Summary?: SummaryConfig | null; /** 标签提取应用配置 */ Classify?: ClassifyConfig | null; } /** 应用详情 */ declare interface AppInfo { /** 应用类型;knowledge_qa-知识问答管理;summary-知识摘要;classifys-知识标签提取 */ AppType?: string | null; /** 应用类型描述 */ AppTypeDesc?: string | null; /** 应用ID */ AppBizId?: string | null; /** 应用名称 */ Name?: string | null; /** 应用头像 */ Avatar?: string | null; /** 应用描述 */ Desc?: string | null; /** 应用状态,1:未上线,2:运行中,3:停用 */ AppStatus?: number | null; /** 状态说明 */ AppStatusDesc?: string | null; /** 修改时间 */ UpdateTime?: string | null; /** 最后修改人 */ Operator?: string | null; /** 模型名称 */ ModelName?: string | null; /** 生成模型别名 */ ModelAliasName?: string | null; /** 应用模式 standard:标准模式, agent: agent模式,single_workflow:单工作流模式 */ Pattern?: string | null; /** 思考模型别名 */ ThoughtModelAliasName?: string | null; /** 权限位信息 */ PermissionIds?: string[]; /** 创建人昵称 */ Creator?: string | null; } /** 应用模型配置 */ declare interface AppModel { /** 模型名称 */ Name?: string | null; /** 模型描述 */ Desc?: string | null; /** 上下文指代轮次 */ ContextLimit?: number | null; /** 模型别名 */ AliasName?: string | null; /** token余量 */ TokenBalance?: number | null; /** 是否使用上下文指代轮次 */ IsUseContext?: boolean | null; /** 上下文记忆轮数 */ HistoryLimit?: number | null; /** 使用类型 */ UsageType?: string | null; /** 模型温度 */ Temperature?: string | null; /** 模型TopP */ TopP?: string | null; /** 模型资源状态 1:资源可用;2:资源已用尽 */ ResourceStatus?: number | null; /** 模型参数 */ ModelParams?: ModelParams | null; } /** 标签详情信息 */ declare interface AttrLabel { /** 标签来源 */ Source?: number | null; /** 标签ID */ AttrBizId?: string | null; /** 标签标识 */ AttrKey?: string | null; /** 标签名称 */ AttrName?: string | null; /** 标签值 */ Labels?: Label[] | null; } /** 标签详情 */ declare interface AttrLabelDetail { /** 标签ID */ AttrBizId?: string | null; /** 标签标识 */ AttrKey?: string | null; /** 标签名称 */ AttrName?: string | null; /** 标签值名称 */ LabelNames?: string[] | null; /** 标签是否在更新中 */ IsUpdating?: boolean | null; /** 状态 */ Status?: number | null; /** 状态描述 */ StatusDesc?: string | null; /** 标签值总数 */ LabelTotalCount?: string; } /** 标签引用信息 */ declare interface AttrLabelRefer { /** 标签来源,1:标签 */ Source?: number; /** 标签ID */ AttributeBizId?: string; /** 标签值ID */ LabelBizIds?: string[]; } /** 导出知识标签过滤器 */ declare interface AttributeFilters { /** 检索,属性或标签名称 */ Query?: string; } /** 标签值 */ declare interface AttributeLabel { /** 标准词ID */ LabelBizId?: string | null; /** 标准词名称 */ LabelName?: string | null; /** 同义词名称 */ SimilarLabels?: string[] | null; } /** 标签值引用的工作流详情 */ declare interface AttributeLabelRefByWorkflow { /** 标签值id */ AttributeLabelBizId?: string; /** 标签值引用的工作流列表 */ WorkflowList?: WorkflowRef[]; } /** 背景图相关配置 */ declare interface BackgroundImageConfig { /** 横图(pc) */ LandscapeImageUrl?: string; /** 原始图 */ OriginalImageUrl?: string; /** 长图(手机) */ PortraitImageUrl?: string; /** 主题色 */ ThemeColor?: string; /** 亮度值 */ Brightness?: number; } /** 应用基础配置 */ declare interface BaseConfig { /** 应用名称 */ Name: string; /** 应用头像url,在CreateApp和ModifyApp中作为入参必填。作为入参传入说明:1. 传入的url图片限制为jpeg和png,大小限制为500KB,url链接需允许head请求。2. 如果用户没有对象存储,可使用“获取文件上传临时密钥”(DescribeStorageCredential)接口,获取cos临时密钥和上传路径,自行上传头像至cos中并获取访问链接。 */ Avatar: string; /** 应用描述 */ Desc?: string; } /** 调用类型 */ declare interface CallDetail { /** 关联ID */ Id?: string | null; /** 调用时间 */ CallTime?: string | null; /** 总token消耗 */ TotalTokenUsage?: number | null; /** 输入token消耗 */ InputTokenUsage?: number | null; /** 输出token消耗 */ OutputTokenUsage?: number | null; /** 搜索服务调用次数 */ SearchUsage?: number | null; /** 模型名称 */ ModelName?: string | null; /** 调用类型 */ CallType?: string | null; /** 账号 */ UinAccount?: string | null; /** 应用名称 */ AppName?: string | null; /** 总消耗页数 */ PageUsage?: number | null; /** 筛选子场景 */ SubScene?: string | null; /** 账单明细对应的自定义tag */ BillingTag?: string; } /** 分类信息 */ declare interface CateInfo { /** 分类ID */ CateBizId?: string | null; /** 分类名称 */ Name?: string | null; /** 分类下的Record(如文档、同义词等)数量 */ Total?: number | null; /** 是否可新增 */ CanAdd?: boolean | null; /** 是否可编辑 */ CanEdit?: boolean | null; /** 是否可删除 */ CanDelete?: boolean | null; /** 子分类 */ Children?: CateInfo[] | null; } /** 标签提取配置 */ declare interface ClassifyConfig { /** 模型配置 */ Model?: AppModel | null; /** 标签列表 */ Labels?: ClassifyLabel[] | null; /** 欢迎语,200字符以内 */ Greeting?: string | null; } /** 标签信息 */ declare interface ClassifyLabel { /** 标签名称 */ Name?: string | null; /** 标签描述 */ Description?: string | null; /** 标签取值范围 */ Values?: string[] | null; } /** 获取不满意回复上下文响 */ declare interface Context { /** 消息记录ID信息 */ RecordBizId?: string | null; /** 是否为用户 */ IsVisitor?: boolean | null; /** 昵称 */ NickName?: string | null; /** 头像 */ Avatar?: string | null; /** 消息内容 */ Content?: string | null; /** 文档信息 */ FileInfos?: MsgFileInfo[] | null; /** 回复方式,15:澄清确认回复 */ ReplyMethod?: number | null; } /** 临时密钥结构 */ declare interface Credentials { /** token */ Token?: string | null; /** 临时证书密钥ID */ TmpSecretId?: string | null; /** 临时证书密钥Key */ TmpSecretKey?: string | null; /** 临时证书appid */ AppId?: number | null; } /** 工作流的API参数 */ declare interface CustomVariable { /** 参数名称 */ Name?: string; /** 参数的值 */ Value?: string; } /** 数智人配置 */ declare interface DigitalHumanConfig { /** 数智人资产key */ AssetKey?: string; /** 数智人名称 */ Name?: string; /** 图像 */ Avatar?: string; /** 预览图 */ PreviewUrl?: string; } /** 文档列表筛选标识位 */ declare interface DocFilterFlag { /** 标识位 */ Flag?: string; /** 标识值 */ Value?: boolean; } /** 文档片段 */ declare interface DocSegment { /** 片段ID */ Id?: string | null; /** 业务ID */ BusinessId?: string | null; /** 文件类型(markdown,word,txt) */ FileType?: string | null; /** 文档切片类型(segment-文档切片 table-表格) */ SegmentType?: string | null; /** 标题 */ Title?: string | null; /** 段落内容 */ PageContent?: string | null; /** 段落原文 */ OrgData?: string | null; /** 文章ID */ DocId?: string | null; /** 文档业务ID */ DocBizId?: string | null; /** 文档链接 */ DocUrl?: string | null; /** 文档的自定义链接 */ WebUrl?: string; /** 页码信息 */ PageInfos?: number[]; } /** 重复文档处理方式 */ declare interface DuplicateFileHandle { /** 重复文档判断方式,1:按文档内容,即cos_hash字段判断是否重复 */ CheckType?: number; /** 重复文档处理方式,1:返回报错,2:跳过,返回重复的文档业务ID */ HandleType?: number; } /** 扩展信息 */ declare interface ExtraInfo { /** ECharts信息 */ EChartsInfo?: string[] | null; } /** 实时上传的文件信息 */ declare interface FileInfo { /** 文件名称 */ FileName?: string | null; /** 文件大小 */ FileSize?: string | null; /** 文件的URL地址,COS地址 */ FileUrl?: string | null; /** 文件类型 */ FileType?: string | null; /** 解析后返回的DocID */ DocId?: string | null; /** 创建时间 */ CreatedAt?: string | null; } /** 不满意回复检索过滤 */ declare interface Filters { /** 检索,用户问题或答案 */ Query?: string; /** 错误类型检索 */ Reasons?: string[]; } /** 获取ws token label */ declare interface GetWsTokenReq_Label { /** 标签名 */ Name?: string; /** 标签值 */ Values?: string[]; } /** 分片高亮内容 */ declare interface Highlight { /** 高亮起始位置 */ StartPos?: string | null; /** 高亮结束位置 */ EndPos?: string | null; /** 高亮子文本 */ Text?: string | null; } /** 多轮历史信息 */ declare interface HistorySummary { /** 助手 */ Assistant?: string | null; /** 用户 */ User?: string | null; } /** 意图达成方式 */ declare interface IntentAchievement { /** 意图达成方式,qa:问答回复、doc:文档回复、workflow:工作流回复,llm:大模型回复 */ Name?: string; /** 意图达成方式描述 */ Desc?: string; } /** 请求的API信息 */ declare interface InvokeAPI { /** 请求方法,如GET/POST等 */ Method?: string | null; /** 请求地址 */ Url?: string | null; /** header参数 */ HeaderValues?: StrValue[] | null; /** 入参Query */ QueryValues?: StrValue[] | null; /** Post请求的原始数据 */ RequestPostBody?: string | null; /** 返回的原始数据 */ ResponseBody?: string | null; /** 出参 */ ResponseValues?: ValueInfo[] | null; /** 异常信息 */ FailMessage?: string | null; } /** 知识库高级设置 */ declare interface KnowledgeAdvancedConfig { /** 重排序模型 */ RerankModel?: string | null; /** 召回数量 */ RerankRecallNum?: number | null; } /** 共享知识库基础信息 */ declare interface KnowledgeBaseInfo { /** 共享知识库业务ID */ KnowledgeBizId?: string; /** 共享知识库名称 */ KnowledgeName?: string; /** 共享知识库描述 */ KnowledgeDescription?: string | null; /** Embedding模型 */ EmbeddingModel?: string | null; /** 问答提取模型 */ QaExtractModel?: string | null; /** 更新时间 */ UpdateTime?: string | null; /** 共享知识库类型,0普通,1公众号 */ KnowledgeType?: number; /** 拥有者id */ OwnerStaffId?: string; /** 知识库文档数量,当前仅支持公众号知识库 */ DocTotal?: number | null; /** 知识库处理中状态标记,1:向量embedding变更中 */ ProcessingFlags?: number[] | null; } /** 知识库容量饼图详情 */ declare interface KnowledgeCapacityPieGraphDetail { /** 当前应用名称 */ AppName?: string | null; /** 当前应用使用的字符数 */ UsedCharSize?: string | null; /** 当前应用对于总用量的占比 */ Proportion?: number | null; /** 知识库类型:0默认1共享 */ KnowledgeType?: number; } /** 应用使用知识库容量详情 */ declare interface KnowledgeDetail { /** 应用名称 */ AppName?: string | null; /** 已用字符数 */ UsedCharSize?: string | null; /** 使用占比 */ Proportion?: number | null; /** 超量字符数 */ ExceedCharSize?: string | null; /** 废弃 */ IsSharedKnowledge?: boolean | null; /** 知识库类型:0默认1共享 */ KnowledgeType?: number; } /** 知识库详情信息 */ declare interface KnowledgeDetailInfo { /** 知识库信息 */ Knowledge?: KnowledgeBaseInfo | null; /** 应用列表 */ AppList?: AppBaseInfo[] | null; /** 用户信息 */ User?: UserBaseInfo | null; /** 权限位信息 */ PermissionIds?: string[]; } /** 知识库模型设置 */ declare interface KnowledgeModelConfig { /** 向量模型,该字段只有共享知识库有,应用知识库没有 */ EmbeddingModel?: string | null; /** 问答对生成模型 */ QaExtractModel?: string | null; /** schema生成模型 */ SchemaModel?: string | null; } /** 应用配置关联的agent信息 */ declare interface KnowledgeQaAgent { /** 协同方式,1:自由转交,2:工作流编排,3:Plan-and-Execute */ AgentCollaboration?: number | null; /** 应用配置agent关联的工作流 */ Workflow?: KnowledgeQaWorkflowInfo | null; } /** 知识问答配置 */ declare interface KnowledgeQaConfig { /** 欢迎语,200字符以内 */ Greeting?: string | null; /** 角色描述,4000字符以内。通过填写描述,设定应用的 #角色名称、 #风格特点 及可达成的#意图。建议按照下面的模板填写,且自定义意图建议不超过5个。#角色名称:#风格特点:#输出要求:#能力限制:能够达成以下用户意图##意图名称:##意图描述:##意图示例:##意图实现: */ RoleDescription?: string | null; /** 生成模型配置 */ Model?: AppModel | null; /** 知识搜索配置 */ Search?: KnowledgeQaSearch[] | null; /** 知识管理输出配置 */ Output?: KnowledgeQaOutput | null; /** 工作流程配置 */ Workflow?: KnowledgeWorkflow | null; /** 检索范围 */ SearchRange?: SearchRange | null; /** 应用模式,standard:标准模式, agent: agent模式,single_workflow:单工作流模式 */ Pattern?: string | null; /** 检索策略 */ SearchStrategy?: SearchStrategy | null; /** 单工作流ID,Pattern为single_workflow时传入 */ SingleWorkflow?: KnowledgeQaSingleWorkflow | null; /** 应用关联插件 */ Plugins?: KnowledgeQaPlugin[] | null; /** 思考模型配置 */ ThoughtModel?: AppModel | null; /** 意图达成方式优先级 */ IntentAchievements?: IntentAchievement[] | null; /** 是否开启图文检索 */ ImageTextRetrieval?: boolean | null; /** 配置语音通话参数 */ AiCall?: AICallConfig | null; /** 共享知识库关联配置 */ ShareKnowledgeBases?: ShareKnowledgeBase[] | null; /** 背景图相关信息 */ BackgroundImage?: BackgroundImageConfig | null; /** 开场问题 */ OpeningQuestions?: string[] | null; /** 长期记忆开关 */ LongMemoryOpen?: boolean; /** 长期记忆时效 */ LongMemoryDay?: number; /** agent配置信息 */ Agent?: KnowledgeQaAgent | null; /** 知识库模型 */ KnowledgeModelConfig?: KnowledgeModelConfig | null; /** 知识库高级设置 */ KnowledgeAdvancedConfig?: KnowledgeAdvancedConfig | null; } /** 应用管理输出配置 */ declare interface KnowledgeQaOutput { /** 输出方式 1:流式 2:非流式 */ Method?: number | null; /** 通用模型回复 */ UseGeneralKnowledge?: boolean | null; /** 未知回复语,300字符以内 */ BareAnswer?: string | null; /** 是否展示问题澄清开关 */ ShowQuestionClarify?: boolean | null; /** 是否打开问题澄清 */ UseQuestionClarify?: boolean | null; /** 问题澄清关键词列表 */ QuestionClarifyKeywords?: string[] | null; /** 是否打开推荐问题开关 */ UseRecommended?: boolean | null; /** 推荐问模式,0.结合知识库&对话历史推荐问题Prompt(默认) 1.仅结合知识库输出推荐问的prompt */ RecommendedPromptMode?: number | null; } /** 应用关联插件信息 */ declare interface KnowledgeQaPlugin { /** 插件ID */ PluginId?: string | null; /** 插件名称 */ PluginName?: string; /** 插件图标 */ PluginIcon?: string; /** 工具ID */ ToolId?: string; /** 工具名称 */ ToolName?: string; /** 工具描述 */ ToolDesc?: string; /** 工具输入参数 */ Inputs?: PluginToolReqParam[]; /** 插件是否和知识库绑定 */ IsBindingKnowledge?: boolean; } /** 检索配置 */ declare interface KnowledgeQaSearch { /** 知识来源 doc:文档,qa:问答 taskflow:业务流程,search:搜索增强,database:数据库 */ Type?: string | null; /** 问答-回复灵活度 1:已采纳答案直接回复 2:已采纳润色后回复 */ ReplyFlexibility?: number | null; /** 搜索增强-搜索引擎状态 */ UseSearchEngine?: boolean | null; /** 是否显示搜索引擎检索状态 */ ShowSearchEngine?: boolean | null; /** 知识来源,是否选择 */ IsEnabled?: boolean | null; /** 问答最大召回数量, 默认2,限制5 */ QaTopN?: number | null; /** 文档最大召回数量, 默认3,限制5 */ DocTopN?: number | null; /** 检索置信度,针对文档和问答有效,最小0.01,最大0.99 */ Confidence?: number | null; /** 资源状态 1:资源可用;2:资源已用尽 */ ResourceStatus?: number | null; } /** 问答知识库单工作流模式下指定单工作流配置 */ declare interface KnowledgeQaSingleWorkflow { /** 工作流ID */ WorkflowId?: string; /** 工作流名称 */ WorkflowName?: string; /** 工作流描述 */ WorkflowDesc?: string; /** 工作流状态,发布状态(UNPUBLISHED: 待发布 PUBLISHING: 发布中 PUBLISHED: 已发布 FAIL:发布失败) */ Status?: string; /** 工作流是否启用 */ IsEnable?: boolean; /** 是否开启异步调用工作流 */ AsyncWorkflow?: boolean; } /** 应用配置关联的工作流信息 */ declare interface KnowledgeQaWorkflowInfo { /** 工作流ID */ WorkflowId?: string; /** 工作流名称 */ WorkflowName?: string; /** 工作流描述 */ WorkflowDesc?: string; /** 工作流状态,发布状态(UNPUBLISHED: 待发布 PUBLISHING: 发布中 PUBLISHED: 已发布 FAIL:发布失败) */ Status?: string; /** 工作流是否启用 */ IsEnable?: boolean; } /** 检索知识 */ declare interface KnowledgeSummary { /** 1是问答 2是文档片段 */ Type?: number | null; /** 知识内容 */ Content?: string | null; } /** 共享知识库更新信息 */ declare interface KnowledgeUpdateInfo { /** 共享知识库名称 */ KnowledgeName?: string; /** 共享知识库描述 */ KnowledgeDescription?: string | null; /** Embedding模型 */ EmbeddingModel?: string | null; /** 问答提取模型 */ QaExtractModel?: string | null; /** 拥有者id */ OwnerStaffId?: string; } /** 问答知识库工作流配置 */ declare interface KnowledgeWorkflow { /** 是否启用工作流 */ IsEnabled?: boolean | null; /** 是否启用PDL */ UsePdl?: boolean | null; } /** 标签ID */ declare interface Label { /** 标签ID */ LabelBizId?: string | null; /** 标签名称 */ LabelName?: string | null; } /** 文档列表详情描述 */ declare interface ListDocItem { /** 文档ID */ DocBizId?: string | null; /** 文件名称 */ FileName?: string | null; /** 重命名的新文档名称,在重命名提交之后,文档发布之前都是这个名称 */ NewName?: string; /** 文件类型 */ FileType?: string | null; /** cos路径 */ CosUrl?: string | null; /** 更新时间 */ UpdateTime?: string | null; /** 文档状态 */ Status?: number | null; /** 文档状态描述 */ StatusDesc?: string | null; /** 原因 */ Reason?: string | null; /** 答案中是否引用 */ IsRefer?: boolean | null; /** 问答对数量 */ QaNum?: number | null; /** 是否已删除 */ IsDeleted?: boolean | null; /** 文档来源 */ Source?: number | null; /** 文档来源描述 */ SourceDesc?: string | null; /** 是否允许重新生成 */ IsAllowRestart?: boolean | null; /** qa是否已删除 */ IsDeletedQa?: boolean | null; /** 问答是否生成中 */ IsCreatingQa?: boolean | null; /** 是否允许删除 */ IsAllowDelete?: boolean | null; /** 是否允许操作引用开关 */ IsAllowRefer?: boolean | null; /** 问答是否生成过 */ IsCreatedQa?: boolean | null; /** 文档字符量 */ DocCharSize?: string | null; /** 属性标签适用范围 */ AttrRange?: number | null; /** 属性标签 */ AttrLabels?: AttrLabel[] | null; /** 是否允许编辑 */ IsAllowEdit?: boolean | null; /** 外部引用链接类型 0:系统链接 1:自定义链接值为1时,WebUrl 字段不能为空,否则不生效。 */ ReferUrlType?: number | null; /** 网页(或自定义链接)地址 */ WebUrl?: string | null; /** 有效开始时间,unix时间戳 */ ExpireStart?: string | null; /** 有效结束时间,unix时间戳,0代表永久有效 */ ExpireEnd?: string | null; /** 是否允许重试,0:否,1:是 */ IsAllowRetry?: boolean | null; /** 0:文档比对处理 1:文档生成问答 */ Processing?: number[] | null; /** 文档创建落库时间 */ CreateTime?: string | null; /** 文档所属分类ID */ CateBizId?: string; /** 文档的用户自定义ID */ CustomerKnowledgeId?: string; /** 文档的属性标记,0: 不做用户外部权限校验 */ AttributeFlags?: number[]; /** false:未停用,ture:已停用 */ IsDisabled?: boolean; /** 员工名称 */ StaffName?: string; } /** 问答详情数据 */ declare interface ListQaItem { /** 问答ID */ QaBizId?: string; /** 问题 */ Question?: string; /** 答案 */ Answer?: string; /** 来源 */ Source?: number; /** 来源描述 */ SourceDesc?: string; /** 更新时间 */ UpdateTime?: string; /** 状态 */ Status?: number; /** 状态描述 */ StatusDesc?: string; /** 文档ID */ DocBizId?: string; /** 创建时间 */ CreateTime?: string; /** 是否允许编辑 */ IsAllowEdit?: boolean; /** 是否允许删除 */ IsAllowDelete?: boolean; /** 是否允许校验 */ IsAllowAccept?: boolean; /** 文档名称 */ FileName?: string; /** 文档类型 */ FileType?: string; /** 问答字符数 */ QaCharSize?: string; /** 有效开始时间,unix时间戳 */ ExpireStart?: string; /** 有效结束时间,unix时间戳,0代表永久有效 */ ExpireEnd?: string; /** 属性标签适用范围 1:全部,2:按条件 */ AttrRange?: number; /** 属性标签 */ AttrLabels?: AttrLabel[]; /** 相似问个数 */ SimilarQuestionNum?: number; /** 返回问答关联的相似问,联动搜索,仅展示一条 */ SimilarQuestionTips?: string; /** 问答是否停用,false:未停用,ture:已停用 */ IsDisabled?: boolean; /** 员工名称 */ StaffName?: string; } /** 发布列表详情 */ declare interface ListReleaseItem { /** 版本ID */ ReleaseBizId?: string; /** 发布人 */ Operator?: string; /** 发布描述 */ Desc?: string; /** 更新时间 */ UpdateTime?: string; /** 发布状态 */ Status?: number; /** 发布状态描述 */ StatusDesc?: string; /** 失败原因 */ Reason?: string; /** 发布成功数 */ SuccessCount?: number; /** 发布失败数 */ FailCount?: number; } /** 模型信息 */ declare interface ModelInfo { /** 模型名称 */ ModelName?: string | null; /** 模型描述 */ ModelDesc?: string | null; /** 模型名称 */ AliasName?: string | null; /** 资源状态 1:资源可用;2:资源已用尽 */ ResourceStatus?: number | null; /** 提示词内容字符限制 */ PromptWordsLimit?: string | null; /** 通过核心采样控制内容生成的多样性,较高的Top P值会导致生成更多样的内容 */ TopP?: ModelParameter | null; /** 温度控制随机性 */ Temperature?: ModelParameter | null; /** 最多能生成的token数量 */ MaxTokens?: ModelParameter | null; /** 模型来源 Hunyuan:腾讯混元大模型,Industry:腾讯云行业大模型,Experience:新模型体验,Custom自定义模型 */ Source?: string; /** 模型图标 */ Icon?: string; /** 是否免费 */ IsFree?: boolean; /** 模型对话框可输入的上限 */ InputLenLimit?: number | null; /** 支持工作流的类型 0:模型不支持; 1: 模型支持工作流; 2: 模型支持效果不佳; */ SupportWorkflowStatus?: number | null; /** 模型类别 generate:生成模型,thought:思考模型 */ ModelCategory?: string; /** 是否默认模型 */ IsDefault?: boolean; /** 角色提示词输入长度限制 */ RoleLenLimit?: number; /** 是否专属并发模型 */ IsExclusive?: boolean; /** 模型支持智能通话效果 */ SupportAiCallStatus?: number; /** 专属并发数 */ Concurrency?: number; /** 模型标签 */ ModelTags?: string[] | null; /** 模型超参定义 */ ModelParams?: ModelParameter[] | null; /** 提供商名称 */ ProviderName?: string; /** 提供商别名 */ ProviderAliasName?: string; /** 提供商类型 Self:提供商,Custom:自定义模型提供商,Third:第三方模型提供商 */ ProviderType?: string; } /** 模型参数范围 */ declare interface ModelParameter { /** 默认值 */ Default?: number | null; /** 最小值 */ Min?: number | null; /** 最大值 */ Max?: number | null; /** 超参名称 */ Name?: string | null; } /** 模型参数 */ declare interface ModelParams { /** 温度 */ Temperature?: number; /** Top_P */ TopP?: number; /** 随机种子 */ Seed?: number; /** 存在惩罚 */ PresencePenalty?: number; /** 频率惩罚 */ FrequencyPenalty?: number; /** 重复惩罚 */ RepetitionPenalty?: number; /** 最大输出长度 */ MaxTokens?: number; /** 停止序列 */ StopSequences?: string[]; /** 输出格式 */ ReplyFormat?: string; } /** 文档信息 */ declare interface MsgFileInfo { /** 文档名称 */ FileName?: string | null; /** 文档大小 */ FileSize?: string | null; /** 文档URL */ FileUrl?: string | null; /** 文档类型 */ FileType?: string | null; /** 文档ID */ DocId?: string | null; } /** 消息详情 */ declare interface MsgRecord { /** 内容 */ Content?: string; /** 当前记录所对应的 Session ID */ SessionId?: string | null; /** 记录ID */ RecordId?: string; /** 关联记录ID */ RelatedRecordId?: string; /** 是否来自自己 */ IsFromSelf?: boolean; /** 发送者名称 */ FromName?: string; /** 发送者头像 */ FromAvatar?: string; /** 时间戳 */ Timestamp?: string; /** 是否已读 */ HasRead?: boolean; /** 评价 */ Score?: number; /** 是否评分 */ CanRating?: boolean; /** 是否展示反馈按钮 */ CanFeedback?: boolean | null; /** 记录类型 */ Type?: number; /** 引用来源 */ References?: MsgRecordReference[]; /** 评价原因 */ Reasons?: string[]; /** 是否大模型 */ IsLlmGenerated?: boolean; /** 图片链接,可公有读 */ ImageUrls?: string[] | null; /** 当次 token 统计信息 */ TokenStat?: TokenStat | null; /** 回复方式1:大模型直接回复;2:保守回复, 未知问题回复;3:拒答问题回复;4:敏感回复;5:问答对直接回复, 已采纳问答对优先回复;6:欢迎语回复;7:并发超限回复;8:全局干预知识;9:任务流程过程回复, 当历史记录中 task_flow.type = 0 时, 为大模型回复;10:任务流程答案回复;11:搜索引擎回复;12:知识润色后回复;13:图片理解回复;14:实时文档回复; */ ReplyMethod?: number | null; /** 选项卡, 用于多轮对话 */ OptionCards?: string[] | null; /** 任务信息 */ TaskFlow?: TaskFlowInfo | null; /** 用户传入的文件信息 */ FileInfos?: FileInfo[] | null; /** 参考来源引用位置信息 */ QuoteInfos?: QuoteInfo[] | null; /** Agent的思考过程信息 */ AgentThought?: AgentThought | null; /** 扩展信息 */ ExtraInfo?: ExtraInfo | null; /** 工作流信息 */ WorkFlow?: WorkflowInfo | null; } /** 聊天详情Refer */ declare interface MsgRecordReference { /** id */ Id?: string; /** 链接 */ Url?: string; /** 类型 */ Type?: number; /** 名称 */ Name?: string; /** 来源文档ID */ DocId?: string; /** 知识库名称 */ KnowledgeName?: string; /** 知识库业务id */ KnowledgeBizId?: string; /** 文档业务id */ DocBizId?: string; /** 问答业务id */ QaBizId?: string; /** 文档索引id */ Index?: number; } /** 节点运行的基本信息 */ declare interface NodeRunBase { /** 节点运行的ID */ NodeRunId?: string; /** 节点ID */ NodeId?: string; /** 工作流运行实例的ID */ WorkflowRunId?: string; /** 节点名称 */ NodeName?: string; /** 节点类型。1: 开始节点2:参数提取节点3:大模型节点4:知识问答节点5:知识检索节点6:标签提取节点7:代码执行节点8:工具节点9:逻辑判断节点10:回复节点11:选项卡节点12:循环节点13:意图识别节点14:工作流节点15:插件节点16:结束节点17: 变量聚合节点数据18: 批处理节点19: 消息队列节点 */ NodeType?: number; /** 运行状态。0: 初始状态;1: 运行中;2: 运行成功; 3: 运行失败; 4: 已取消 */ State?: number; /** 错误码 */ FailCode?: string; /** 错误信息 */ FailMessage?: string; /** 消耗时间(毫秒) */ CostMilliseconds?: number; /** 消耗的token总数 */ TotalTokens?: number; } /** 工作流节点运行详情 */ declare interface NodeRunDetail { /** 节点运行的ID */ NodeRunId?: string; /** 节点ID */ NodeId?: string; /** 工作流运行实例的ID */ WorkflowRunId?: string; /** 节点名称 */ NodeName?: string; /** 节点类型。1: 开始节点2:参数提取节点3:大模型节点4:知识问答节点5:知识检索节点6:标签提取节点7:代码执行节点8:工具节点9:逻辑判断节点10:回复节点11:选项卡节点12:循环节点13:意图识别节点14:工作流节点15:插件节点16:结束节点17: 变量聚合节点数据18: 批处理节点19: 消息队列节点 */ NodeType?: number; /** 运行状态。0: 初始状态;1: 运行中;2: 运行成功; 3: 运行失败; 4: 已取消 */ State?: number; /** 错误码 */ FailCode?: string; /** 错误信息 */ FailMessage?: string; /** 消耗时间(毫秒) */ CostMilliseconds?: number; /** 消耗的token总数 */ TotalTokens?: number; /** 输入变量信息 */ Input?: string; /** 节点的输入的完整内容的链接。(当Input内容超过限制的时候此字段才有值) */ InputRef?: string; /** 输出变量信息 */ Output?: string; /** 节点的输出的完整内容的链接。(当Output内容超过限制的时候此字段才有值) */ OutputRef?: string; /** 原始输出信息。部分节点才有值,如工具节点、代码节点 */ TaskOutput?: string; /** 任务的原始输出的完整内容的链接。(当TaskOutput内容超过限制的时候此字段才有值) */ TaskOutputRef?: string; /** 节点的日志 */ Log?: string; /** 节点的日志的完整内容的链接志(当Log内容超过限制的时候才有值) */ LogRef?: string; /** 开始时间戳(毫秒) */ StartTime?: string; /** 结束时间戳(毫秒) */ EndTime?: string; /** LLM统计信息。 */ StatisticInfos?: StatisticInfo[]; } /** 下拉框选项 */ declare interface Option { /** 文本 */ Text?: string | null; /** 值 */ Value?: string | null; /** 文件字符数 */ CharSize?: string | null; /** 文件类型 */ FileType?: string | null; } /** 选项卡索引 */ declare interface OptionCardIndex { /** 唯一标识 */ RecordId?: string; /** 选项卡索引 */ Index?: number; } /** 插件参数请求结构 */ declare interface PluginToolReqParam { /** 参数名称 */ Name?: string; /** 参数描述 */ Desc?: string; /** 参数类型,0:string, 1:int, 2:float,3:bool 4:object 5:array_string, 6:array_int, 7:array_float, 8:array_bool, 9:array_object, 99:null, 100:upspecified */ Type?: number; /** 参数是否必填 */ IsRequired?: boolean; /** 参数默认值 */ DefaultValue?: string; /** 子参数,ParamType 是OBJECT 或 ARRAY<>类型有用 */ SubParams?: PluginToolReqParam[]; /** 插件参数配置是否隐藏不可见,true-隐藏不可见,false-可见 */ GlobalHidden?: boolean; /** OneOf类型参数 */ OneOf?: PluginToolReqParam[]; /** AnyOf类型参数 */ AnyOf?: PluginToolReqParam[]; } /** 执行过程信息记录 */ declare interface Procedure { /** 执行过程英语名 */ Name?: string | null; /** 中文名, 用于展示 */ Title?: string | null; /** 状态常量: 使用中: processing, 成功: success, 失败: failed */ Status?: string | null; /** 消耗 token 数 */ Count?: number | null; /** 调试信息 */ Debugging?: ProcedureDebugging | null; /** 计费资源状态,1:可用,2:不可用 */ ResourceStatus?: number | null; /** 输入消耗 token 数 */ InputCount?: number; /** 输出消耗 token 数 */ OutputCount?: number; } /** 调试信息 */ declare interface ProcedureDebugging { /** 检索query */ Content?: string | null; /** 系统prompt */ System?: string | null; /** 多轮历史信息 */ Histories?: HistorySummary[] | null; /** 检索知识 */ Knowledge?: KnowledgeSummary[] | null; /** 任务流程 */ TaskFlow?: TaskFlowSummary | null; /** 工作流调试信息 */ WorkFlow?: WorkFlowSummary | null; /** Agent调试信息 */ Agent?: AgentDebugInfo | null; /** 自定义参数 */ CustomVariables?: string[] | null; } /** 获取QA分类分组 */ declare interface QACate { /** QA分类的业务ID */ CateBizId?: string | null; /** 分类名称 */ Name?: string | null; /** 分类下QA数量 */ Total?: number | null; /** 是否可新增 */ CanAdd?: boolean | null; /** 是否可编辑 */ CanEdit?: boolean | null; /** 是否可删除 */ CanDelete?: boolean | null; /** 子分类 */ Children?: QACate[] | null; } /** 问答列表 */ declare interface QAList { /** 问答ID */ QaBizId: string; /** 是否采纳 */ IsAccepted?: boolean; /** 分类ID */ CateBizId?: string; /** 问题 */ Question?: string; /** 答案 */ Answer?: string; } /** QA查询参数 */ declare interface QAQuery { /** 页码 */ PageNumber: number; /** 每页数量 */ PageSize: number; /** 应用ID */ BotBizId: string; /** 查询内容 */ Query?: string; /** 分类ID */ CateBizId?: string; /** 校验状态 */ AcceptStatus?: number[]; /** 发布状态 */ ReleaseStatus?: number[]; /** 文档ID */ DocBizId?: string; /** QAID */ QaBizId?: string; /** 来源 */ Source?: number; /** 查询答案 */ QueryAnswer?: string; /** 查询类型 filename 名称、 attribute 标签 */ QueryType?: string; } /** 搜索引擎参考来源索引 */ declare interface QuoteInfo { /** 参考来源位置 */ Position?: number | null; /** 参考来源索引顺序 */ Index?: string | null; } /** 引用来源详情 */ declare interface ReferDetail { /** 引用ID */ ReferBizId?: string | null; /** 文档类型 (1 QA, 2 文档段) */ DocType?: number | null; /** 文档名称 */ DocName?: string | null; /** 分片内容 */ PageContent?: string | null; /** 问题 */ Question?: string | null; /** 答案 */ Answer?: string | null; /** 置信度 */ Confidence?: number | null; /** 标记 */ Mark?: number | null; /** 分片高亮内容 */ Highlights?: Highlight[] | null; /** 原始内容 */ OrgData?: string | null; /** 页码信息 */ PageInfos?: number[] | null; /** sheet信息 */ SheetInfos?: string[] | null; /** 文档ID */ DocBizId?: string | null; /** 知识库ID */ KnowledgeBizId?: string; } /** 发布拒答 */ declare interface RejectedQuestion { /** 拒答问题ID */ RejectedBizId?: string | null; /** 被拒答的问题 */ Question?: string | null; /** 状态 */ Status?: number | null; /** 状态描述 */ StatusDesc?: string | null; /** 更新时间 */ UpdateTime?: string | null; /** 是否允许编辑 */ IsAllowEdit?: boolean | null; /** 是否允许删除 */ IsAllowDelete?: boolean | null; } /** 发布配置项 */ declare interface ReleaseConfigs { /** 配置项描述 */ ConfigItem?: string | null; /** 更新时间 */ UpdateTime?: string | null; /** 状态 */ Action?: number | null; /** 变更后的内容 */ Value?: string | null; /** 变更前的内容 */ LastValue?: string | null; /** 变更内容(优先级展示content内容,content为空取value内容) */ Content?: string | null; /** 失败原因 */ Message?: string | null; } /** 发布文档详情 */ declare interface ReleaseDoc { /** 文件名 */ FileName?: string; /** 文件类型 */ FileType?: string; /** 更新时间 */ UpdateTime?: string; /** 状态 */ Action?: number; /** 状态描述 */ ActionDesc?: string; /** 失败原因 */ Message?: string; /** 文档业务ID */ DocBizId?: string; } /** 发布问答 */ declare interface ReleaseQA { /** 问题 */ Question?: string; /** 更新时间 */ UpdateTime?: string; /** 状态 */ Action?: number; /** 状态描述 */ ActionDesc?: string; /** 来源1:文档生成,2:批量导入,3:手动添加 */ Source?: number; /** 来源描述 */ SourceDesc?: string; /** 文件名字 */ FileName?: string; /** 文档类型 */ FileType?: string; /** 失败原因 */ Message?: string; /** 发布状态 */ ReleaseStatus?: number; /** QAID */ QaBizId?: string; /** 文档业务ID */ DocBizId?: string; } /** 发布拒答 */ declare interface ReleaseRejectedQuestion { /** 问题 */ Question?: string | null; /** 更新时间 */ UpdateTime?: string | null; /** 状态 */ Action?: number | null; /** 状态描述 */ ActionDesc?: string | null; /** 失败原因 */ Message?: string | null; } /** 节点信息 */ declare interface RunNodeInfo { /** 节点类型,0:未指定,1:开始节点,2:API节点,3:询问节点,4:答案节点 */ NodeType?: number | null; /** 节点ID */ NodeId?: string | null; /** 节点名称 */ NodeName?: string | null; /** 请求的API */ InvokeApi?: InvokeAPI | null; /** 当前节点的所有槽位的值,key:SlotID。没有值的时候也要返回空。 */ SlotValues?: ValueInfo[] | null; } /** 检索范围配置 */ declare interface SearchRange { /** 检索条件and/or */ Condition?: string | null; /** 自定义变量和标签关系数据 */ ApiVarAttrInfos?: ApiVarAttrInfo[] | null; } /** 知识库检索策略 */ declare interface SearchStrategy { /** 检索策略类型 0:混合检索,1:语义检索 */ StrategyType?: number | null; /** Excel检索增强开关, false关闭,true打开 */ TableEnhancement?: boolean | null; /** 向量模型 */ EmbeddingModel?: string | null; /** 结果重排序开关, on打开,off关闭 */ RerankModelSwitch?: string | null; /** 结果重排序模型 */ RerankModel?: string | null; } /** 共享知识库配置 */ declare interface ShareKnowledgeBase { /** 共享知识库ID */ KnowledgeBizId?: string | null; /** 检索范围 */ SearchRange?: SearchRange | null; /** 知识库模型设置 */ KnowledgeModelConfig?: KnowledgeModelConfig | null; /** 检索策略配置 */ SearchStrategy?: SearchStrategy | null; /** 检索配置 */ Search?: KnowledgeQaSearch[] | null; /** // 问答-回复灵活度 1:已采纳答案直接回复 2:已采纳润色后回复 */ ReplyFlexibility?: number | null; /** 共享知识库名称 */ KnowledgeName?: string | null; } /** 相似问信息 */ declare interface SimilarQuestion { /** 相似问ID */ SimBizId?: string | null; /** 相似问内容 */ Question?: string | null; /** 相似问审核状态,1审核失败 */ AuditStatus?: number | null; } /** 相似问修改(更新)信息 */ declare interface SimilarQuestionModify { /** 需要添加的相似问(内容)列表 */ AddQuestions?: string[]; /** 需要更新的相似问列表 */ UpdateQuestions?: SimilarQuestion[]; /** 需要删除的相似问列表 */ DeleteQuestions?: SimilarQuestion[]; } /** 计费统计信息 */ declare interface Stat { /** X轴: 时间区域;根据查询条件的粒度返回“分/小时/日”三种区间范围 */ X?: string | null; /** Y轴: 该时间区域内的统计值,如token消耗量,调用次数或使用量等信息 */ Y?: number | null; } /** 大模型token统计信息 */ declare interface StatisticInfo { /** 模型名称 */ ModelName?: string | null; /** 首Token耗时 */ FirstTokenCost?: number | null; /** 总耗时 */ TotalCost?: number | null; /** 输入Token数量 */ InputTokens?: number | null; /** 输出Token数量 */ OutputTokens?: number | null; /** 总Token数量 */ TotalTokens?: number | null; } /** 字符串KV信息 */ declare interface StrValue { /** 名称 */ Name?: string | null; /** 值 */ Value?: string | null; } /** 知识摘要应用配置 */ declare interface SummaryConfig { /** 模型配置 */ Model?: AppModel | null; /** 知识摘要输出配置 */ Output?: SummaryOutput | null; /** 欢迎语,200字符以内 */ Greeting?: string | null; } /** 知识摘要输出配置 */ declare interface SummaryOutput { /** 输出方式 1:流式 2:非流式 */ Method?: number | null; /** 输出要求 1:文本总结 2:自定义要求 */ Requirement?: number | null; /** 自定义要求指令 */ RequireCommand?: string | null; } /** 变量详情 */ declare interface TaskFLowVar { /** 变量ID */ VarId?: string | null; /** 变量名称 */ VarName?: string | null; /** 变量描述(默认为"-") */ VarDesc?: string; /** 变量类型 (STRING,INT,FLOAT,BOOL,OBJECT,ARRAY_STRING,ARRAY_INT,ARRAY_FLOAT,ARRAY_BOOL,ARRAY_OBJECT,FILE,DOCUMENT,IMAGE,AUDIO) */ VarType?: string; /** 自定义变量默认值 */ VarDefaultValue?: string; /** 自定义变量文件默认名称 */ VarDefaultFileName?: string; /** 变量类型 */ VarModuleType?: number; } /** 任务流程信息 */ declare interface TaskFlowInfo { /** 任务流程ID */ TaskFlowId?: string | null; /** 任务流程名称 */ TaskFlowName?: string | null; /** Query 重写结果 */ QueryRewrite?: string | null; /** 命中意图 */ HitIntent?: string | null; /** 任务流程回复类型0: 任务流回复1: 任务流静默2: 任务流拉回话术3: 任务流自定义回复 */ Type?: number | null; } /** 任务流程调试信息 */ declare interface TaskFlowSummary { /** 任务流程名 */ IntentName?: string | null; /** 实体列表 */ UpdatedSlotValues?: ValueInfo[] | null; /** 节点列表 */ RunNodes?: RunNodeInfo[] | null; /** 意图判断 */ Purposes?: string[] | null; } /** 任务参数 */ declare interface TaskParams { /** 下载地址,需要通过cos桶临时密钥去下载 */ CosPath?: string | null; } /** 当前执行的 token 统计信息 */ declare interface TokenStat { /** 会话 ID */ SessionId?: string | null; /** 请求 ID */ RequestId?: string | null; /** 对应哪条会话, 会话 ID, 用于回答的消息存储使用, 可提前生成, 保存消息时使用 */ RecordId?: string | null; /** token 已使用数 */ UsedCount?: number | null; /** 免费 token 数 */ FreeCount?: number | null; /** 订单总 token 数 */ OrderCount?: number | null; /** 当前执行状态汇总, 常量: 使用中: processing, 成功: success, 失败: failed */ StatusSummary?: string | null; /** 当前执行状态汇总后中文展示 */ StatusSummaryTitle?: string | null; /** 当前请求执行时间, 单位 ms */ Elapsed?: number | null; /** 当前请求消耗 token 数 */ TokenCount?: number | null; /** 执行过程信息 */ Procedures?: Procedure[] | null; /** 执行过程信息TraceId */ TraceId?: string | null; } /** 不满意回复 */ declare interface UnsatisfiedReply { /** 不满意回复ID */ ReplyBizId?: string | null; /** 消息记录ID */ RecordBizId?: string | null; /** 用户问题 */ Question?: string | null; /** 应用回复 */ Answer?: string | null; /** 错误类型 */ Reasons?: string[] | null; } /** 更新时间策略 */ declare interface UpdatePeriodInfo { /** 文档更新频率类型:0不更新 -H 小时粒度,当前仅支持24(1天),72(3天),168(7天) 仅source=2 腾讯文档类型有效 */ UpdatePeriodH?: number | null; } /** 用户基础信息 */ declare interface UserBaseInfo { /** 用户ID */ UserBizId?: string; /** 用户名称 */ UserName?: string | null; } /** 任务流程参数信息 */ declare interface ValueInfo { /** 值ID */ Id?: string | null; /** 名称 */ Name?: string | null; /** 值类型:0:未知或者空, 1:string, 2:int, 3:float, 4:bool, 5:array(字符串数组), 6: object_array(结构体数组), 7: object(结构体) */ ValueType?: number | null; /** string */ ValueStr?: string | null; /** int(避免精度丢失使用字符串返回) */ ValueInt?: string | null; /** float */ ValueFloat?: number | null; /** bool */ ValueBool?: boolean | null; /** array */ ValueStrArray?: string[] | null; } /** 音色参数 */ declare interface VoiceConfig { /** 公有云音色id */ VoiceType?: number | null; /** 音色key */ TimbreKey?: string | null; /** 音色名称 */ VoiceName?: string | null; } /** 工作流程调试信息 */ declare interface WorkFlowSummary { /** 工作流ID */ WorkflowId?: string | null; /** 工作流名称 */ WorkflowName?: string | null; /** 工作流运行ID */ WorkflowRunId?: string | null; /** 节点信息 */ RunNodes?: WorkflowRunNodeInfo[] | null; /** 选项卡 */ OptionCards?: string[] | null; /** 多气泡的输出结果 */ Outputs?: string[] | null; /** 工作流发布时间,unix时间戳 */ WorkflowReleaseTime?: string | null; /** 中间消息 */ PendingMessages?: string[]; /** 选项卡索引 */ OptionCardIndex?: OptionCardIndex; } /** 工作流信息 */ declare interface WorkflowInfo { /** 工作流ID */ WorkflowId?: string | null; /** 工作流名称 */ WorkflowName?: string | null; /** 工作流运行ID */ WorkflowRunId?: string | null; /** 选项卡 */ OptionCards?: string[] | null; /** 多气泡的输出结果 */ Outputs?: string[] | null; /** 工作流发布时间,unix时间戳 */ WorkflowReleaseTime?: string | null; } /** WorkflowRef详情 */ declare interface WorkflowRef { /** 任务流ID */ WorkflowId?: string; /** 任务流名称 */ WorkflowName?: string; /** 任务流描述 */ WorkflowDesc?: string; /** 应用ID */ AppBizId?: string; /** 更新时间 */ UpdateTime?: number; } /** 工作流运行实例的基本信息 */ declare interface WorkflowRunBase { /** 运行环境。0: 测试环境; 1: 正式环境 */ RunEnv?: number; /** 应用ID */ AppBizId?: string; /** 工作流运行实例的ID */ WorkflowRunId?: string; /** 所属工作流ID */ WorkflowId?: string; /** 名称 */ Name?: string; /** 运行状态。0: 排队中;1: 运行中;2: 运行成功;3: 运行失败; 4: 已取消 */ State?: number; /** 错误信息 */ FailMessage?: string; /** 消耗的token总数 */ TotalTokens?: number; /** 创建时间(毫秒时间戳) */ CreateTime?: string; /** 开始时间(毫秒时间戳) */ StartTime?: string; /** 结束时间(毫秒时间戳) */ EndTime?: string; } /** 工作流运行实例详情 */ declare interface WorkflowRunDetail { /** 运行环境。0: 测试环境; 1: 正式环境 */ RunEnv?: number; /** 应用ID */ AppBizId?: string; /** 工作流运行实例的ID */ WorkflowRunId?: string; /** 所属工作流ID */ WorkflowId?: string; /** 名称 */ Name?: string; /** 工作流输出 */ Output?: string; /** 运行状态。0: 排队中;1: 运行中;2: 运行成功;3: 运行失败; 4: 已取消 */ State?: number; /** 错误信息 */ FailMessage?: string; /** 消耗的token总数 */ TotalTokens?: number; /** 创建时间(毫秒时间戳) */ CreateTime?: string; /** 开始时间(毫秒时间戳) */ StartTime?: string; /** 结束时间(毫秒时间戳) */ EndTime?: string; /** 工作流画布Json */ DialogJson?: string; /** 用户的输入 */ Query?: string; /** 主模型名称 */ MainModelName?: string; /** API参数配置 */ CustomVariables?: CustomVariable[]; } /** 工作流运行节点信息 */ declare interface WorkflowRunNodeInfo { /** 节点ID */ NodeId?: string | null; /** 节点类型 */ NodeType?: number | null; /** 节点名称 */ NodeName?: string | null; /** 状态 */ Status?: number | null; /** 输入 */ Input?: string | null; /** 输出 */ Output?: string | null; /** 任务输出 */ TaskOutput?: string | null; /** 错误信息 */ FailMessage?: string | null; /** 花费时长 */ CostMilliSeconds?: number | null; /** 大模型输出信息 */ StatisticInfos?: StatisticInfo[] | null; } declare interface CheckAttributeLabelExistRequest { /** 应用ID */ BotBizId: string; /** 属性名称 */ LabelName: string; /** 属性ID */ AttributeBizId: string; /** 登录用户主账号(集成商模式必填) */ LoginUin?: string; /** 登录用户子账号(集成商模式必填) */ LoginSubAccountUin?: string; /** 滚动加载,最后一个属性标签ID */ LastLabelBizId?: string; } declare interface CheckAttributeLabelExistResponse { /** 是否存在 */ IsExist?: boolean; /** 唯一请求 ID,每次请求都会返回。 */ RequestId?: string; } declare interface CheckAttributeLabelReferRequest { /** 应用ID */ BotBizId: string; /** 登录用户主账号(集成商模式必填) */ LoginUin?: string; /** 登录用户子账号(集成商模式必填) */ LoginSubAccountUin?: string; /** 属性标签 */ LabelBizId?: string; /** 属性ID */ AttributeBizId?: string[]; } declare interface CheckAttributeLabelReferResponse { /** 是否引用 */ IsRefer?: boolean; /** 引用的工作流详情 */ List?: AttributeLabelRefByWorkflow[] | null; /** 唯一请求 ID,每次请求都会返回。 */ RequestId?: string; } declare interface CreateAgentRequest { /** 应用ID */ AppBizId?: string; /** 要增加的Agent的信息 */ Agent?: Agent; } declare interface CreateAgentResponse { /** 新建的AgentID */ AgentId?: string; /** 唯一请求 ID,每次请求都会返回。 */ RequestId?: string; } declare interface CreateAppRequest { /** 应用类型;knowledge_qa-知识问答管理 */ AppType: string; /** 应用基础配置 */ BaseConfig: BaseConfig; /** 应用模式 standard:标准模式, agent: agent模式,single_workflow:单工作流模式 */ Pattern?: string; /** 智能体类型 dialogue 对话式智能体,wechat 公众号智能体 */ AgentType?: string; } declare interface CreateAppResponse { /** 应用ID */ AppBizId?: string | null; /** 判断账户应用列表权限是否是自定义的,用户交互提示 */ IsCustomList?: boolean | null; /** 唯一请求 ID,每次请求都会返回。 */ RequestId?: string; } declare interface CreateAttributeLabelRequest { /** 应用ID */ BotBizId: string; /** 标签名 */ AttrName: string; /** 标签值 */ Labels: AttributeLabel[]; /** 标签标识(不生效,无需填写) 已作废 */ AttrKey?: string; /** 登录用户主账号(集成商模式必填) */ LoginUin?: string; /** 登录用户子账号(集成商模式必填) */ LoginSubAccountUin?: string; } declare interface CreateAttributeLabelResponse { /** 标签ID */ AttrB