feature:新增大纲续写-智能生成组织功能,自动添加组织成员

This commit is contained in:
xiamuceer
2026-01-05 14:27:27 +08:00
parent 6e603ee1a9
commit ba7ee591b6
6 changed files with 1986 additions and 84 deletions
+8
View File
@@ -18,6 +18,7 @@ export interface SSEClientOptions {
onComplete?: () => void;
onConnectionError?: (error: Event) => void;
onCharacterConfirmation?: (data: any) => void; // 新增:角色确认回调
onOrganizationConfirmation?: (data: any) => void; // 新增:组织确认回调
}
export class SSEClient {
@@ -200,6 +201,13 @@ export class SSEPostClient {
}
currentEvent = ''; // 重置事件类型
return; // 暂停流程,等待用户确认
} else if (currentEvent === 'organization_confirmation_required') {
// 处理组织确认事件
if (this.options.onOrganizationConfirmation) {
this.options.onOrganizationConfirmation(data);
}
currentEvent = ''; // 重置事件类型
return; // 暂停流程,等待用户确认
} else {
// 标准消息处理
const message: SSEMessage = data;