| | |
| | | End = 'end', |
| | | Condition = 'condition', |
| | | Knowledge = 'knowledge', |
| | | Output = 'output_msg', |
| | | Agent='agent' |
| | | } |
| | | |
| | | export const nodeTypeMap = { |
| | |
| | | [NodeType.End]: '结束', |
| | | [NodeType.Condition]: '条件判断', |
| | | [NodeType.Knowledge]: '知识库', |
| | | [NodeType.Output]: '输出', |
| | | [NodeType.Agent]: '代理', |
| | | |
| | | }; |
| | | |
| | | export const enum CompareOperation { |
| | | /** @description 包含 */ |
| | | include = 'include', |
| | | /** @description 不包含 */ |
| | | notInclude = 'notInclude', |
| | | /** @description 为空 */ |
| | | empty = 'empty', |
| | | /** @description 不为空 */ |
| | | notEmpty = 'notEmpty', |
| | | /** @description 开始为 */ |
| | | startWith = 'startWith', |
| | | /** @description 结束为 */ |
| | | endWith = 'endWith', |
| | | |
| | | /** @description 等于 */ |
| | | eq = 'eq', |
| | | /** @description 不等于 */ |
| | | neq = 'neq', |
| | | /** @description 大于 */ |
| | | gt = 'gt', |
| | | /** @description 小于 */ |
| | |
| | | lte = 'lte', |
| | | } |
| | | export const compareOperationMap = { |
| | | [CompareOperation.gt]: '>', |
| | | [CompareOperation.lt]: '<', |
| | | [CompareOperation.gte]: '≥', |
| | | [CompareOperation.lte]: '≤', |
| | | [CompareOperation.gt]: '大于', |
| | | [CompareOperation.lt]: '小于', |
| | | [CompareOperation.gte]: '大于或等于', |
| | | [CompareOperation.lte]: '小于或等于', |
| | | [CompareOperation.eq]: '等于', |
| | | [CompareOperation.neq]: '不等于', |
| | | [CompareOperation.include]: '包含', |
| | | [CompareOperation.notInclude]: '不包含', |
| | | [CompareOperation.empty]: '为空', |
| | | [CompareOperation.notEmpty]: '不为空', |
| | | [CompareOperation.startWith]: '开始为', |
| | | [CompareOperation.endWith]: '结束为', |
| | | }; |
| | | |
| | | export const enum VarType { |
| | |
| | | [ConditionOperator.And]: '且', |
| | | [ConditionOperator.Or]: '或', |
| | | }; |
| | | |
| | | // 交互类型 |
| | | export const enum InteractionType { |
| | | // 无交互 |
| | | None = 'none', |
| | | // 选择型交互 |
| | | Select = 'select', |
| | | // 输入型交互 |
| | | Input = 'input', |
| | | } |
| | | |
| | | export const interactionTypeMap = { |
| | | [InteractionType.None]: '无交互', |
| | | [InteractionType.Select]: '选择型交互', |
| | | [InteractionType.Input]: '输入型交互', |
| | | }; |