Update workflow

This commit is contained in:
Xin Wang
2026-02-02 10:10:24 +08:00
parent ae391a8aa7
commit 75914cf2e6
7 changed files with 1017 additions and 282 deletions

View File

@@ -12,6 +12,15 @@ export interface Assistant {
hotwords: string[];
}
export interface Voice {
id: string;
name: string;
vendor: string;
gender: string;
language: string;
description: string;
}
export interface KnowledgeBase {
id: string;
name: string;
@@ -36,21 +45,54 @@ export interface CallLog {
agentName: string;
}
export interface UserProfile {
username: string;
avatarUrl: string;
email: string;
language: 'zh' | 'en';
}
export interface Voice {
export interface Workflow {
id: string;
name: string;
vendor: 'Ali' | 'Volcano' | 'Minimax';
gender: 'Male' | 'Female';
language: 'zh' | 'en';
description?: string;
previewUrl?: string; // Mock url
nodeCount: number;
createdAt: string;
updatedAt: string;
nodes: WorkflowNode[];
edges: WorkflowEdge[];
globalPrompt?: string;
}
export interface WorkflowNode {
name: string;
type: 'conversation' | 'tool' | 'human' | 'end';
isStart?: boolean;
metadata: {
position: { x: number; y: number };
};
prompt?: string;
messagePlan?: {
firstMessage?: string;
};
variableExtractionPlan?: {
output: Array<{
type: string;
title: string;
description: string;
}>;
};
tool?: {
type: string;
function: {
name: string;
parameters: any;
};
destinations?: any[];
messages?: any[];
};
globalNodePlan?: {
enabled: boolean;
enterCondition: string;
};
}
export interface WorkflowEdge {
from: string;
to: string;
label?: string;
}
export enum TabValue {