@ibiz-template-plugin/ai-chat 0.0.84 → 0.0.86

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,55 @@
1
+ /**
2
+ * @description 深度研究步骤项
3
+ * @author tony001
4
+ * @date 2026-06-10 10:06:20
5
+ * @export
6
+ * @interface IDeepResearchStepItem
7
+ */
8
+ export interface IDeepResearchStepItem {
9
+ /**
10
+ * 名称(简写)
11
+ */
12
+ abbr_name: string;
13
+ /**
14
+ * 名称
15
+ */
16
+ name: string;
17
+ /**
18
+ * 状态,初始化 | 处理中 | 完成
19
+ */
20
+ status: 'init' | 'processing' | 'complete';
21
+ /**
22
+ * 思考内容,需动态链接[(xxxxxxx)]资源
23
+ *
24
+ * 格式如:通过研究,我已掌握2023-2026年新能源汽车市场关键数据,包括渗透率突破30%、41.83%、47.9%-53%及70%的关键节点。需进一步确认2025年渗透率数据差异及获取2026年上半年最新数据,以完善从增量到存量的市场转变分析。
25
+ * [(deep_research_source_1)]
26
+ * 经调研发现2026年5月新能源车零售渗透率已达62.9%,批发达61.1%,创历史新高。市场已进入存量竞争阶段,2025年突破50%是关键转折点。值得注意的是插混/增程在2024年增速反超纯电,但2026年纯电占比又回升。下步将分析技术路线分化趋势和出口支撑作用。
27
+ *
28
+ */
29
+ think_content: string;
30
+ }
31
+ /**
32
+ * @description 深度研究步骤
33
+ * @author tony001
34
+ * @date 2026-06-10 11:06:30
35
+ * @export
36
+ * @interface IDeepResearchStep
37
+ */
38
+ export interface IDeepResearchStep {
39
+ /**
40
+ * 显示文本
41
+ */
42
+ display_text: string;
43
+ /**
44
+ * 文档数量
45
+ */
46
+ doc_count: number;
47
+ /**
48
+ * 状态,初始化 | 处理中 | 完成
49
+ */
50
+ status: 'init' | 'processing' | 'complete';
51
+ /**
52
+ * 步骤项集合
53
+ */
54
+ step: IDeepResearchStepItem[];
55
+ }
@@ -0,0 +1,5 @@
1
+ export type { IDeepResearchStepItem, IDeepResearchStep, } from './i-deep-research-step';
2
+ export type { IDeepResearchResource } from './i-deep-research-resource';
3
+ export type { IDeepResearchResourceWebItem, IDeepResearchResourceWeb, } from './i-deep-research-source-web';
4
+ export type { IDeepResearchReport } from './i-deep-research-report';
5
+ export type { IDeepResearchItem } from './i-deep-research-item';
@@ -0,0 +1,115 @@
1
+ /**
2
+ * @description AI问题选项
3
+ * @author tony001
4
+ * @date 2026-05-26 11:05:32
5
+ * @export
6
+ * @interface IAIQuesitionItem
7
+ */
8
+ export interface IAIQuesitionItem {
9
+ /**
10
+ * @description 问题选项值
11
+ * @author tony001
12
+ * @date 2026-05-26 11:05:12
13
+ * @type {string}
14
+ * @memberof IAIQuesitionItem
15
+ */
16
+ value: string;
17
+ /**
18
+ * @description 问题选项标题
19
+ * @author tony001
20
+ * @date 2026-05-26 11:05:49
21
+ * @type {string}
22
+ * @memberof IAIQuesitionItem
23
+ */
24
+ caption: string;
25
+ /**
26
+ * @description 问题选项描述
27
+ * @author tony001
28
+ * @date 2026-05-26 11:05:26
29
+ * @type {string}
30
+ * @memberof IAIQuesitionItem
31
+ */
32
+ description?: string;
33
+ }
34
+ /**
35
+ * @description AI问题,基于该数据结构出界面
36
+ * @author tony001
37
+ * @date 2026-05-26 11:05:51
38
+ * @export
39
+ * @interface IAIQuesition
40
+ */
41
+ export interface IAIQuesition {
42
+ /**
43
+ * @description 问题标识
44
+ * @author tony001
45
+ * @date 2026-05-26 11:05:25
46
+ * @type {string}
47
+ * @memberof IAIQuesition
48
+ */
49
+ id: string;
50
+ /**
51
+ * @description 问题标题
52
+ * @author tony001
53
+ * @date 2026-05-26 11:05:44
54
+ * @type {string}
55
+ * @memberof IAIQuesition
56
+ */
57
+ caption: string;
58
+ /**
59
+ * @description 问题类型
60
+ * @author tony001
61
+ * @date 2026-05-26 11:05:32
62
+ * @type {('RADIO' | 'CHECKBOX' | 'INPUT')}
63
+ * @memberof IAIQuesition
64
+ */
65
+ type: 'RADIO' | 'CHECKBOX' | 'INPUT';
66
+ /**
67
+ * @description 问题排序
68
+ * @author tony001
69
+ * @date 2026-05-26 11:05:19
70
+ * @type {number}
71
+ * @memberof IAIQuesition
72
+ */
73
+ order: number;
74
+ /**
75
+ * @description 问题选项集合
76
+ * @author tony001
77
+ * @date 2026-05-26 11:05:18
78
+ * @type {IAIQuesitionItem[]}
79
+ * @memberof IAIQuesition
80
+ */
81
+ items: IAIQuesitionItem[];
82
+ }
83
+ /**
84
+ * @description 问题答案,基于该数据结构返回给AI
85
+ * @author tony001
86
+ * @date 2026-05-26 11:05:38
87
+ * @export
88
+ * @interface IAIQuesitionAnswer
89
+ */
90
+ export interface IAIQuesitionAnswer {
91
+ /**
92
+ * @description 标识
93
+ * @author tony001
94
+ * @date 2026-05-26 11:05:32
95
+ * @type {string}
96
+ * @memberof IAIQuesitionAnswer
97
+ */
98
+ id: string;
99
+ /**
100
+ * @description 自定义文本
101
+ * @author tony001
102
+ * @date 2026-05-27 11:05:42
103
+ * @type {string}
104
+ * @memberof IAIQuesitionAnswer
105
+ */
106
+ customText: string;
107
+ /**
108
+ * @description 问题答案值
109
+ * @author tony001
110
+ * @date 2026-05-26 11:05:10
111
+ * @type {string}
112
+ * @memberof IAIQuesitionAnswer
113
+ */
114
+ value: string;
115
+ }
@@ -340,7 +340,7 @@ export interface IChatOptions extends IChat {
340
340
  *
341
341
  * @returns
342
342
  */
343
- fetchKnowledgeBaseList?: () => Promise<IKnowledgeBase[]>;
343
+ fetchKnowledgeBaseList?: (query?: string) => Promise<IKnowledgeBase[]>;
344
344
  /**
345
345
  * 文件上传配置
346
346
  *
@@ -20,3 +20,5 @@ export type { IKnowledgeBase } from './i-knowledge-base/i-knowledge-base';
20
20
  export type { IConfirmUtil, IConfirmParams, INotificationUtil, INotificationParams, IMessageUtil, IMessageParams, } from './util';
21
21
  export type { IChatMessageUsage } from './i-chat-message-usage/i-chat-message-usage';
22
22
  export type { IChatController } from './i-chat-controller/i-chat-controller';
23
+ export type { IAIQuesitionItem, IAIQuesition, IAIQuesitionAnswer, } from './i-ai-quesition/i-ai-quesition';
24
+ export * from './deep-research';
@@ -98,6 +98,12 @@ export declare const EN: {
98
98
  temporarySessionFailed: string;
99
99
  reedit: string;
100
100
  cancel: string;
101
+ questionPrev: string;
102
+ questionNext: string;
103
+ questionSubmit: string;
104
+ questionInputPlaceholder: string;
105
+ questionOther: string;
106
+ questionNoData: string;
101
107
  send: string;
102
108
  unknownError: string;
103
109
  statistics: string;
@@ -107,4 +113,14 @@ export declare const EN: {
107
113
  toolCallCount: string;
108
114
  notCounted: string;
109
115
  notCalled: string;
116
+ noResearchContent: string;
117
+ light: string;
118
+ dark: string;
119
+ generateVisualReport: string;
120
+ sourceMaterial: string;
121
+ searchKeyword: string;
122
+ deepResearch: string;
123
+ textReport: string;
124
+ deepResearchReport: string;
125
+ noTextReportContent: string;
110
126
  };
@@ -98,6 +98,12 @@ export declare const ZH_CN: {
98
98
  temporarySessionFailed: string;
99
99
  reedit: string;
100
100
  cancel: string;
101
+ questionPrev: string;
102
+ questionNext: string;
103
+ questionSubmit: string;
104
+ questionInputPlaceholder: string;
105
+ questionOther: string;
106
+ questionNoData: string;
101
107
  send: string;
102
108
  unknownError: string;
103
109
  statistics: string;
@@ -107,4 +113,14 @@ export declare const ZH_CN: {
107
113
  toolCallCount: string;
108
114
  notCounted: string;
109
115
  notCalled: string;
116
+ noResearchContent: string;
117
+ light: string;
118
+ dark: string;
119
+ generateVisualReport: string;
120
+ sourceMaterial: string;
121
+ searchKeyword: string;
122
+ deepResearch: string;
123
+ textReport: string;
124
+ deepResearchReport: string;
125
+ noTextReportContent: string;
110
126
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ibiz-template-plugin/ai-chat",
3
- "version": "0.0.84",
3
+ "version": "0.0.86",
4
4
  "description": "iBiz AI交互框插件",
5
5
  "type": "module",
6
6
  "main": "dist/index.es.js",
@@ -34,6 +34,7 @@
34
34
  "@tiptap/core": "^3.11.1",
35
35
  "@tiptap/extension-document": "^3.11.1",
36
36
  "@tiptap/extension-file-handler": "^3.11.1",
37
+ "@tiptap/extension-hard-break": "^3.12.0",
37
38
  "@tiptap/extension-image": "^3.11.1",
38
39
  "@tiptap/extension-paragraph": "^3.11.1",
39
40
  "@tiptap/extension-text": "^3.11.1",