Add analysis feature
This commit is contained in:
@@ -246,6 +246,27 @@ export type SystemToolKind =
|
||||
| "skip_turn"
|
||||
| "request_human_handoff";
|
||||
|
||||
export type AnalysisFieldType =
|
||||
| "string"
|
||||
| "boolean"
|
||||
| "integer"
|
||||
| "number"
|
||||
| "enum";
|
||||
|
||||
export type AnalysisField = {
|
||||
id: string;
|
||||
name: string;
|
||||
type: AnalysisFieldType;
|
||||
description: string;
|
||||
enumValues: string[];
|
||||
};
|
||||
|
||||
export type AnalysisConfig = {
|
||||
enabled: boolean;
|
||||
modelResourceId: string;
|
||||
fields: AnalysisField[];
|
||||
};
|
||||
|
||||
/** 后端 AssistantOut(宽表 STI:瘦字段平铺,workflow 用 graph)。apiKey 读时打码 */
|
||||
export type Assistant = {
|
||||
id: string;
|
||||
@@ -264,6 +285,7 @@ export type Assistant = {
|
||||
toolIds: string[];
|
||||
prompt: string;
|
||||
dynamicVariableDefinitions: Record<string, DynamicVariableDefinition>;
|
||||
analysisConfig: AnalysisConfig;
|
||||
apiUrl: string;
|
||||
apiKey: string;
|
||||
appId: string;
|
||||
@@ -354,6 +376,16 @@ export type ConversationDetail = Conversation & {
|
||||
};
|
||||
workflowTrace?: Array<Record<string, unknown>>;
|
||||
};
|
||||
analysis: {
|
||||
status: "none" | "pending" | "processing" | "completed" | "failed";
|
||||
fields: Array<{
|
||||
name: string;
|
||||
type: AnalysisFieldType;
|
||||
value: unknown;
|
||||
}>;
|
||||
error: string;
|
||||
completedAt: string | null;
|
||||
};
|
||||
messages: ConversationMessage[];
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user