@alicloud/aimiaobi20230801 1.35.4 → 1.36.0

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.
Files changed (117) hide show
  1. package/dist/client.d.ts +136 -0
  2. package/dist/client.js +667 -127
  3. package/dist/client.js.map +1 -1
  4. package/dist/models/CreateGeneralConfigRequest.d.ts +37 -0
  5. package/dist/models/CreateGeneralConfigRequest.js +62 -0
  6. package/dist/models/CreateGeneralConfigRequest.js.map +1 -0
  7. package/dist/models/CreateGeneralConfigResponse.d.ts +19 -0
  8. package/dist/models/CreateGeneralConfigResponse.js +69 -0
  9. package/dist/models/CreateGeneralConfigResponse.js.map +1 -0
  10. package/dist/models/CreateGeneralConfigResponseBody.d.ts +71 -0
  11. package/dist/models/CreateGeneralConfigResponseBody.js +96 -0
  12. package/dist/models/CreateGeneralConfigResponseBody.js.map +1 -0
  13. package/dist/models/DeleteGeneralConfigRequest.d.ts +29 -0
  14. package/dist/models/DeleteGeneralConfigRequest.js +60 -0
  15. package/dist/models/DeleteGeneralConfigRequest.js.map +1 -0
  16. package/dist/models/DeleteGeneralConfigResponse.d.ts +19 -0
  17. package/dist/models/DeleteGeneralConfigResponse.js +69 -0
  18. package/dist/models/DeleteGeneralConfigResponse.js.map +1 -0
  19. package/dist/models/DeleteGeneralConfigResponseBody.d.ts +38 -0
  20. package/dist/models/DeleteGeneralConfigResponseBody.js +66 -0
  21. package/dist/models/DeleteGeneralConfigResponseBody.js.map +1 -0
  22. package/dist/models/GetGeneralConfigRequest.d.ts +29 -0
  23. package/dist/models/GetGeneralConfigRequest.js +60 -0
  24. package/dist/models/GetGeneralConfigRequest.js.map +1 -0
  25. package/dist/models/GetGeneralConfigResponse.d.ts +19 -0
  26. package/dist/models/GetGeneralConfigResponse.js +69 -0
  27. package/dist/models/GetGeneralConfigResponse.js.map +1 -0
  28. package/dist/models/GetGeneralConfigResponseBody.d.ts +71 -0
  29. package/dist/models/GetGeneralConfigResponseBody.js +96 -0
  30. package/dist/models/GetGeneralConfigResponseBody.js.map +1 -0
  31. package/dist/models/ListDocumentRetrieveRequest.d.ts +81 -0
  32. package/dist/models/ListDocumentRetrieveRequest.js +82 -0
  33. package/dist/models/ListDocumentRetrieveRequest.js.map +1 -0
  34. package/dist/models/ListDocumentRetrieveResponse.d.ts +19 -0
  35. package/dist/models/ListDocumentRetrieveResponse.js +69 -0
  36. package/dist/models/ListDocumentRetrieveResponse.js.map +1 -0
  37. package/dist/models/ListDocumentRetrieveResponseBody.d.ts +98 -0
  38. package/dist/models/ListDocumentRetrieveResponseBody.js +104 -0
  39. package/dist/models/ListDocumentRetrieveResponseBody.js.map +1 -0
  40. package/dist/models/ListGeneralConfigsRequest.d.ts +31 -0
  41. package/dist/models/ListGeneralConfigsRequest.js +62 -0
  42. package/dist/models/ListGeneralConfigsRequest.js.map +1 -0
  43. package/dist/models/ListGeneralConfigsResponse.d.ts +19 -0
  44. package/dist/models/ListGeneralConfigsResponse.js +69 -0
  45. package/dist/models/ListGeneralConfigsResponse.js.map +1 -0
  46. package/dist/models/ListGeneralConfigsResponseBody.d.ts +86 -0
  47. package/dist/models/ListGeneralConfigsResponseBody.js +102 -0
  48. package/dist/models/ListGeneralConfigsResponseBody.js.map +1 -0
  49. package/dist/models/RunQuickWritingRequest.d.ts +74 -0
  50. package/dist/models/RunQuickWritingRequest.js +116 -0
  51. package/dist/models/RunQuickWritingRequest.js.map +1 -0
  52. package/dist/models/RunQuickWritingResponse.d.ts +19 -0
  53. package/dist/models/RunQuickWritingResponse.js +69 -0
  54. package/dist/models/RunQuickWritingResponse.js.map +1 -0
  55. package/dist/models/RunQuickWritingResponseBody.d.ts +130 -0
  56. package/dist/models/RunQuickWritingResponseBody.js +170 -0
  57. package/dist/models/RunQuickWritingResponseBody.js.map +1 -0
  58. package/dist/models/RunQuickWritingShrinkRequest.d.ts +33 -0
  59. package/dist/models/RunQuickWritingShrinkRequest.js +66 -0
  60. package/dist/models/RunQuickWritingShrinkRequest.js.map +1 -0
  61. package/dist/models/RunSearchGenerationRequest.d.ts +30 -0
  62. package/dist/models/RunSearchGenerationRequest.js +12 -0
  63. package/dist/models/RunSearchGenerationRequest.js.map +1 -1
  64. package/dist/models/RunTopicSelectionMergeRequest.d.ts +28 -0
  65. package/dist/models/RunTopicSelectionMergeRequest.js +66 -0
  66. package/dist/models/RunTopicSelectionMergeRequest.js.map +1 -0
  67. package/dist/models/RunTopicSelectionMergeResponse.d.ts +19 -0
  68. package/dist/models/RunTopicSelectionMergeResponse.js +69 -0
  69. package/dist/models/RunTopicSelectionMergeResponse.js.map +1 -0
  70. package/dist/models/RunTopicSelectionMergeResponseBody.d.ts +140 -0
  71. package/dist/models/RunTopicSelectionMergeResponseBody.js +183 -0
  72. package/dist/models/RunTopicSelectionMergeResponseBody.js.map +1 -0
  73. package/dist/models/RunTopicSelectionMergeShrinkRequest.d.ts +27 -0
  74. package/dist/models/RunTopicSelectionMergeShrinkRequest.js +62 -0
  75. package/dist/models/RunTopicSelectionMergeShrinkRequest.js.map +1 -0
  76. package/dist/models/UpdateGeneralConfigRequest.d.ts +37 -0
  77. package/dist/models/UpdateGeneralConfigRequest.js +62 -0
  78. package/dist/models/UpdateGeneralConfigRequest.js.map +1 -0
  79. package/dist/models/UpdateGeneralConfigResponse.d.ts +19 -0
  80. package/dist/models/UpdateGeneralConfigResponse.js +69 -0
  81. package/dist/models/UpdateGeneralConfigResponse.js.map +1 -0
  82. package/dist/models/UpdateGeneralConfigResponseBody.d.ts +71 -0
  83. package/dist/models/UpdateGeneralConfigResponseBody.js +96 -0
  84. package/dist/models/UpdateGeneralConfigResponseBody.js.map +1 -0
  85. package/dist/models/model.d.ts +41 -0
  86. package/dist/models/model.js +107 -25
  87. package/dist/models/model.js.map +1 -1
  88. package/package.json +1 -1
  89. package/src/client.ts +586 -0
  90. package/src/models/CreateGeneralConfigRequest.ts +54 -0
  91. package/src/models/CreateGeneralConfigResponse.ts +40 -0
  92. package/src/models/CreateGeneralConfigResponseBody.ts +113 -0
  93. package/src/models/DeleteGeneralConfigRequest.ts +44 -0
  94. package/src/models/DeleteGeneralConfigResponse.ts +40 -0
  95. package/src/models/DeleteGeneralConfigResponseBody.ts +59 -0
  96. package/src/models/GetGeneralConfigRequest.ts +44 -0
  97. package/src/models/GetGeneralConfigResponse.ts +40 -0
  98. package/src/models/GetGeneralConfigResponseBody.ts +113 -0
  99. package/src/models/ListDocumentRetrieveRequest.ts +118 -0
  100. package/src/models/ListDocumentRetrieveResponse.ts +40 -0
  101. package/src/models/ListDocumentRetrieveResponseBody.ts +148 -0
  102. package/src/models/ListGeneralConfigsRequest.ts +48 -0
  103. package/src/models/ListGeneralConfigsResponse.ts +40 -0
  104. package/src/models/ListGeneralConfigsResponseBody.ts +134 -0
  105. package/src/models/RunQuickWritingRequest.ts +127 -0
  106. package/src/models/RunQuickWritingResponse.ts +40 -0
  107. package/src/models/RunQuickWritingResponseBody.ts +219 -0
  108. package/src/models/RunQuickWritingShrinkRequest.ts +54 -0
  109. package/src/models/RunSearchGenerationRequest.ts +42 -0
  110. package/src/models/RunTopicSelectionMergeRequest.ts +48 -0
  111. package/src/models/RunTopicSelectionMergeResponse.ts +40 -0
  112. package/src/models/RunTopicSelectionMergeResponseBody.ts +239 -0
  113. package/src/models/RunTopicSelectionMergeShrinkRequest.ts +44 -0
  114. package/src/models/UpdateGeneralConfigRequest.ts +54 -0
  115. package/src/models/UpdateGeneralConfigResponse.ts +40 -0
  116. package/src/models/UpdateGeneralConfigResponseBody.ts +113 -0
  117. package/src/models/model.ts +41 -0
@@ -0,0 +1,219 @@
1
+ // This file is auto-generated, don't edit it
2
+ import * as $dara from '@darabonba/typescript';
3
+
4
+
5
+ export class RunQuickWritingResponseBodyHeader extends $dara.Model {
6
+ /**
7
+ * @example
8
+ * 错误码
9
+ */
10
+ errorCode?: string;
11
+ /**
12
+ * @example
13
+ * 错误信息
14
+ */
15
+ errorMessage?: string;
16
+ /**
17
+ * @example
18
+ * task-started
19
+ */
20
+ event?: string;
21
+ /**
22
+ * @example
23
+ * 3f7045e099474ba28ceca1b4eb6d6e21
24
+ */
25
+ sessionId?: string;
26
+ /**
27
+ * @example
28
+ * 400
29
+ */
30
+ statusCode?: number;
31
+ /**
32
+ * @example
33
+ * 3f7045e099474ba28ceca1b4eb6d6e21
34
+ */
35
+ taskId?: string;
36
+ /**
37
+ * @example
38
+ * 全链路ID
39
+ */
40
+ traceId?: string;
41
+ static names(): { [key: string]: string } {
42
+ return {
43
+ errorCode: 'ErrorCode',
44
+ errorMessage: 'ErrorMessage',
45
+ event: 'Event',
46
+ sessionId: 'SessionId',
47
+ statusCode: 'StatusCode',
48
+ taskId: 'TaskId',
49
+ traceId: 'TraceId',
50
+ };
51
+ }
52
+
53
+ static types(): { [key: string]: any } {
54
+ return {
55
+ errorCode: 'string',
56
+ errorMessage: 'string',
57
+ event: 'string',
58
+ sessionId: 'string',
59
+ statusCode: 'number',
60
+ taskId: 'string',
61
+ traceId: 'string',
62
+ };
63
+ }
64
+
65
+ validate() {
66
+ super.validate();
67
+ }
68
+
69
+ constructor(map?: { [key: string]: any }) {
70
+ super(map);
71
+ }
72
+ }
73
+
74
+ export class RunQuickWritingResponseBodyPayloadOutput extends $dara.Model {
75
+ /**
76
+ * @example
77
+ * 文本生成结果
78
+ */
79
+ text?: string;
80
+ static names(): { [key: string]: string } {
81
+ return {
82
+ text: 'Text',
83
+ };
84
+ }
85
+
86
+ static types(): { [key: string]: any } {
87
+ return {
88
+ text: 'string',
89
+ };
90
+ }
91
+
92
+ validate() {
93
+ super.validate();
94
+ }
95
+
96
+ constructor(map?: { [key: string]: any }) {
97
+ super(map);
98
+ }
99
+ }
100
+
101
+ export class RunQuickWritingResponseBodyPayloadUsage extends $dara.Model {
102
+ /**
103
+ * @example
104
+ * 78
105
+ */
106
+ inputTokens?: number;
107
+ /**
108
+ * @example
109
+ * 34
110
+ */
111
+ outputTokens?: number;
112
+ /**
113
+ * @example
114
+ * 38
115
+ */
116
+ totalTokens?: number;
117
+ static names(): { [key: string]: string } {
118
+ return {
119
+ inputTokens: 'InputTokens',
120
+ outputTokens: 'OutputTokens',
121
+ totalTokens: 'TotalTokens',
122
+ };
123
+ }
124
+
125
+ static types(): { [key: string]: any } {
126
+ return {
127
+ inputTokens: 'number',
128
+ outputTokens: 'number',
129
+ totalTokens: 'number',
130
+ };
131
+ }
132
+
133
+ validate() {
134
+ super.validate();
135
+ }
136
+
137
+ constructor(map?: { [key: string]: any }) {
138
+ super(map);
139
+ }
140
+ }
141
+
142
+ export class RunQuickWritingResponseBodyPayload extends $dara.Model {
143
+ output?: RunQuickWritingResponseBodyPayloadOutput;
144
+ usage?: RunQuickWritingResponseBodyPayloadUsage;
145
+ static names(): { [key: string]: string } {
146
+ return {
147
+ output: 'Output',
148
+ usage: 'Usage',
149
+ };
150
+ }
151
+
152
+ static types(): { [key: string]: any } {
153
+ return {
154
+ output: RunQuickWritingResponseBodyPayloadOutput,
155
+ usage: RunQuickWritingResponseBodyPayloadUsage,
156
+ };
157
+ }
158
+
159
+ validate() {
160
+ if(this.output && typeof (this.output as any).validate === 'function') {
161
+ (this.output as any).validate();
162
+ }
163
+ if(this.usage && typeof (this.usage as any).validate === 'function') {
164
+ (this.usage as any).validate();
165
+ }
166
+ super.validate();
167
+ }
168
+
169
+ constructor(map?: { [key: string]: any }) {
170
+ super(map);
171
+ }
172
+ }
173
+
174
+ export class RunQuickWritingResponseBody extends $dara.Model {
175
+ /**
176
+ * @example
177
+ * false
178
+ */
179
+ end?: boolean;
180
+ header?: RunQuickWritingResponseBodyHeader;
181
+ payload?: RunQuickWritingResponseBodyPayload;
182
+ /**
183
+ * @example
184
+ * 3f7045e099474ba28ceca1b4eb6d6e21
185
+ */
186
+ requestId?: string;
187
+ static names(): { [key: string]: string } {
188
+ return {
189
+ end: 'End',
190
+ header: 'Header',
191
+ payload: 'Payload',
192
+ requestId: 'RequestId',
193
+ };
194
+ }
195
+
196
+ static types(): { [key: string]: any } {
197
+ return {
198
+ end: 'boolean',
199
+ header: RunQuickWritingResponseBodyHeader,
200
+ payload: RunQuickWritingResponseBodyPayload,
201
+ requestId: 'string',
202
+ };
203
+ }
204
+
205
+ validate() {
206
+ if(this.header && typeof (this.header as any).validate === 'function') {
207
+ (this.header as any).validate();
208
+ }
209
+ if(this.payload && typeof (this.payload as any).validate === 'function') {
210
+ (this.payload as any).validate();
211
+ }
212
+ super.validate();
213
+ }
214
+
215
+ constructor(map?: { [key: string]: any }) {
216
+ super(map);
217
+ }
218
+ }
219
+
@@ -0,0 +1,54 @@
1
+ // This file is auto-generated, don't edit it
2
+ import * as $dara from '@darabonba/typescript';
3
+
4
+
5
+ export class RunQuickWritingShrinkRequest extends $dara.Model {
6
+ articlesShrink?: string;
7
+ /**
8
+ * @remarks
9
+ * This parameter is required.
10
+ */
11
+ prompt?: string;
12
+ searchSourcesShrink?: string;
13
+ /**
14
+ * @example
15
+ * 3f7045e099474ba28ceca1b4eb6d6e21
16
+ */
17
+ taskId?: string;
18
+ /**
19
+ * @remarks
20
+ * This parameter is required.
21
+ *
22
+ * @example
23
+ * xxxx
24
+ */
25
+ workspaceId?: string;
26
+ static names(): { [key: string]: string } {
27
+ return {
28
+ articlesShrink: 'Articles',
29
+ prompt: 'Prompt',
30
+ searchSourcesShrink: 'SearchSources',
31
+ taskId: 'TaskId',
32
+ workspaceId: 'WorkspaceId',
33
+ };
34
+ }
35
+
36
+ static types(): { [key: string]: any } {
37
+ return {
38
+ articlesShrink: 'string',
39
+ prompt: 'string',
40
+ searchSourcesShrink: 'string',
41
+ taskId: 'string',
42
+ workspaceId: 'string',
43
+ };
44
+ }
45
+
46
+ validate() {
47
+ super.validate();
48
+ }
49
+
50
+ constructor(map?: { [key: string]: any }) {
51
+ super(map);
52
+ }
53
+ }
54
+
@@ -325,7 +325,27 @@ export class RunSearchGenerationRequestChatConfigSearchParam extends $dara.Model
325
325
  */
326
326
  endTime?: number;
327
327
  multimodalSearchTypes?: string[];
328
+ /**
329
+ * @example
330
+ * 0.6
331
+ */
332
+ searchAudioMinScore?: number;
333
+ /**
334
+ * @example
335
+ * 0.6
336
+ */
337
+ searchImageMinScore?: number;
328
338
  searchSources?: RunSearchGenerationRequestChatConfigSearchParamSearchSources[];
339
+ /**
340
+ * @example
341
+ * 0.6
342
+ */
343
+ searchTextMinScore?: number;
344
+ /**
345
+ * @example
346
+ * 0.6
347
+ */
348
+ searchVideoMinScore?: number;
329
349
  /**
330
350
  * @example
331
351
  * 1725983999999
@@ -335,7 +355,11 @@ export class RunSearchGenerationRequestChatConfigSearchParam extends $dara.Model
335
355
  return {
336
356
  endTime: 'EndTime',
337
357
  multimodalSearchTypes: 'MultimodalSearchTypes',
358
+ searchAudioMinScore: 'SearchAudioMinScore',
359
+ searchImageMinScore: 'SearchImageMinScore',
338
360
  searchSources: 'SearchSources',
361
+ searchTextMinScore: 'SearchTextMinScore',
362
+ searchVideoMinScore: 'SearchVideoMinScore',
339
363
  startTime: 'StartTime',
340
364
  };
341
365
  }
@@ -344,7 +368,11 @@ export class RunSearchGenerationRequestChatConfigSearchParam extends $dara.Model
344
368
  return {
345
369
  endTime: 'number',
346
370
  multimodalSearchTypes: { 'type': 'array', 'itemType': 'string' },
371
+ searchAudioMinScore: 'number',
372
+ searchImageMinScore: 'number',
347
373
  searchSources: { 'type': 'array', 'itemType': RunSearchGenerationRequestChatConfigSearchParamSearchSources },
374
+ searchTextMinScore: 'number',
375
+ searchVideoMinScore: 'number',
348
376
  startTime: 'number',
349
377
  };
350
378
  }
@@ -377,6 +405,16 @@ export class RunSearchGenerationRequestChatConfig extends $dara.Model {
377
405
  * copilotPrecise
378
406
  */
379
407
  generateTechnology?: string;
408
+ /**
409
+ * @example
410
+ * # 角色 你是一个专业的文章检索和问答机器人,擅长文章检索和回答用户问题。 # 任务目标 请你根据检索到的相关文章,回答或表述用户问题“{query}”。 # 任务限制 - 如果用户问题中提到具体日期,请考虑知识日期做筛选。 - 生成内容结构条理。 - 生成内容尽量精简。 - 控制在30字以内 - 不要使用其他数据,不要杜撰。 - 如果不能回答用户问题,请输出对应语言的拒识文案: - 中文:\"根据已知信息无法回答。\" - 英文:\"Unable to answer based on the known information.\" # 输入数据 ## 检索到的相关文章 {content}
411
+ */
412
+ modelCustomPromptTemplate?: string;
413
+ /**
414
+ * @example
415
+ * # 角色 你是一个专业的文章检索和问答机器人,擅长文章检索和回答用户问题。 # 任务目标 请你根据检索到的相关文章和图片,回答或表述用户问题“{query}”。 # 任务限制 - 如果用户问题中提到具体日期,请考虑知识日期做筛选。 - 生成内容结构条理。 - 生成内容尽量精简。 - 控制在30字以内。 - 如果图片内容可以回答,可以忽略文章内容。 - 不要使用其他数据,不要杜撰。 - 如果不能回答用户问题,请输出对应语言的拒识文案: - 中文:\"根据已知信息无法回答。\" - 英文:\"Unable to answer based on the known information.\" # 输入数据 ## 检索到的相关文章 {content}
416
+ */
417
+ modelCustomVlPromptTemplate?: string;
380
418
  searchModels?: string[];
381
419
  searchParam?: RunSearchGenerationRequestChatConfigSearchParam;
382
420
  static names(): { [key: string]: string } {
@@ -385,6 +423,8 @@ export class RunSearchGenerationRequestChatConfig extends $dara.Model {
385
423
  excludeGenerateOptions: 'ExcludeGenerateOptions',
386
424
  generateLevel: 'GenerateLevel',
387
425
  generateTechnology: 'GenerateTechnology',
426
+ modelCustomPromptTemplate: 'ModelCustomPromptTemplate',
427
+ modelCustomVlPromptTemplate: 'ModelCustomVlPromptTemplate',
388
428
  searchModels: 'SearchModels',
389
429
  searchParam: 'SearchParam',
390
430
  };
@@ -396,6 +436,8 @@ export class RunSearchGenerationRequestChatConfig extends $dara.Model {
396
436
  excludeGenerateOptions: { 'type': 'array', 'itemType': 'string' },
397
437
  generateLevel: 'string',
398
438
  generateTechnology: 'string',
439
+ modelCustomPromptTemplate: 'string',
440
+ modelCustomVlPromptTemplate: 'string',
399
441
  searchModels: { 'type': 'array', 'itemType': 'string' },
400
442
  searchParam: RunSearchGenerationRequestChatConfigSearchParam,
401
443
  };
@@ -0,0 +1,48 @@
1
+ // This file is auto-generated, don't edit it
2
+ import * as $dara from '@darabonba/typescript';
3
+ import { TopicSelection } from "./TopicSelection";
4
+
5
+
6
+ export class RunTopicSelectionMergeRequest extends $dara.Model {
7
+ prompt?: string;
8
+ /**
9
+ * @remarks
10
+ * This parameter is required.
11
+ */
12
+ topics?: TopicSelection[];
13
+ /**
14
+ * @remarks
15
+ * This parameter is required.
16
+ *
17
+ * @example
18
+ * xxxx
19
+ */
20
+ workspaceId?: string;
21
+ static names(): { [key: string]: string } {
22
+ return {
23
+ prompt: 'Prompt',
24
+ topics: 'Topics',
25
+ workspaceId: 'WorkspaceId',
26
+ };
27
+ }
28
+
29
+ static types(): { [key: string]: any } {
30
+ return {
31
+ prompt: 'string',
32
+ topics: { 'type': 'array', 'itemType': TopicSelection },
33
+ workspaceId: 'string',
34
+ };
35
+ }
36
+
37
+ validate() {
38
+ if(Array.isArray(this.topics)) {
39
+ $dara.Model.validateArray(this.topics);
40
+ }
41
+ super.validate();
42
+ }
43
+
44
+ constructor(map?: { [key: string]: any }) {
45
+ super(map);
46
+ }
47
+ }
48
+
@@ -0,0 +1,40 @@
1
+ // This file is auto-generated, don't edit it
2
+ import * as $dara from '@darabonba/typescript';
3
+ import { RunTopicSelectionMergeResponseBody } from "./RunTopicSelectionMergeResponseBody";
4
+
5
+
6
+ export class RunTopicSelectionMergeResponse extends $dara.Model {
7
+ headers?: { [key: string]: string };
8
+ statusCode?: number;
9
+ body?: RunTopicSelectionMergeResponseBody;
10
+ static names(): { [key: string]: string } {
11
+ return {
12
+ headers: 'headers',
13
+ statusCode: 'statusCode',
14
+ body: 'body',
15
+ };
16
+ }
17
+
18
+ static types(): { [key: string]: any } {
19
+ return {
20
+ headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
21
+ statusCode: 'number',
22
+ body: RunTopicSelectionMergeResponseBody,
23
+ };
24
+ }
25
+
26
+ validate() {
27
+ if(this.headers) {
28
+ $dara.Model.validateMap(this.headers);
29
+ }
30
+ if(this.body && typeof (this.body as any).validate === 'function') {
31
+ (this.body as any).validate();
32
+ }
33
+ super.validate();
34
+ }
35
+
36
+ constructor(map?: { [key: string]: any }) {
37
+ super(map);
38
+ }
39
+ }
40
+
@@ -0,0 +1,239 @@
1
+ // This file is auto-generated, don't edit it
2
+ import * as $dara from '@darabonba/typescript';
3
+ import { TopicSelection } from "./TopicSelection";
4
+
5
+
6
+ export class RunTopicSelectionMergeResponseBodyHeader extends $dara.Model {
7
+ /**
8
+ * @example
9
+ * 错误码
10
+ */
11
+ errorCode?: string;
12
+ /**
13
+ * @example
14
+ * 错误信息
15
+ */
16
+ errorMessage?: string;
17
+ /**
18
+ * @example
19
+ * task-started
20
+ */
21
+ event?: string;
22
+ /**
23
+ * @example
24
+ * 3f7045e099474ba28ceca1b4eb6d6e21
25
+ */
26
+ originSessionId?: string;
27
+ /**
28
+ * @example
29
+ * 3f7045e099474ba28ceca1b4eb6d6e21
30
+ */
31
+ sessionId?: string;
32
+ /**
33
+ * @example
34
+ * 400
35
+ */
36
+ statusCode?: number;
37
+ /**
38
+ * @example
39
+ * 3f7045e099474ba28ceca1b4eb6d6e21
40
+ */
41
+ taskId?: string;
42
+ /**
43
+ * @example
44
+ * 全链路ID
45
+ */
46
+ traceId?: string;
47
+ static names(): { [key: string]: string } {
48
+ return {
49
+ errorCode: 'ErrorCode',
50
+ errorMessage: 'ErrorMessage',
51
+ event: 'Event',
52
+ originSessionId: 'OriginSessionId',
53
+ sessionId: 'SessionId',
54
+ statusCode: 'StatusCode',
55
+ taskId: 'TaskId',
56
+ traceId: 'TraceId',
57
+ };
58
+ }
59
+
60
+ static types(): { [key: string]: any } {
61
+ return {
62
+ errorCode: 'string',
63
+ errorMessage: 'string',
64
+ event: 'string',
65
+ originSessionId: 'string',
66
+ sessionId: 'string',
67
+ statusCode: 'number',
68
+ taskId: 'string',
69
+ traceId: 'string',
70
+ };
71
+ }
72
+
73
+ validate() {
74
+ super.validate();
75
+ }
76
+
77
+ constructor(map?: { [key: string]: any }) {
78
+ super(map);
79
+ }
80
+ }
81
+
82
+ export class RunTopicSelectionMergeResponseBodyPayloadOutput extends $dara.Model {
83
+ /**
84
+ * @example
85
+ * 文本生成结果
86
+ */
87
+ text?: string;
88
+ topic?: TopicSelection;
89
+ static names(): { [key: string]: string } {
90
+ return {
91
+ text: 'Text',
92
+ topic: 'Topic',
93
+ };
94
+ }
95
+
96
+ static types(): { [key: string]: any } {
97
+ return {
98
+ text: 'string',
99
+ topic: TopicSelection,
100
+ };
101
+ }
102
+
103
+ validate() {
104
+ if(this.topic && typeof (this.topic as any).validate === 'function') {
105
+ (this.topic as any).validate();
106
+ }
107
+ super.validate();
108
+ }
109
+
110
+ constructor(map?: { [key: string]: any }) {
111
+ super(map);
112
+ }
113
+ }
114
+
115
+ export class RunTopicSelectionMergeResponseBodyPayloadUsage extends $dara.Model {
116
+ /**
117
+ * @example
118
+ * 78
119
+ */
120
+ inputTokens?: number;
121
+ /**
122
+ * @example
123
+ * 34
124
+ */
125
+ outputTokens?: number;
126
+ tokenMap?: { [key: string]: number };
127
+ /**
128
+ * @example
129
+ * 38
130
+ */
131
+ totalTokens?: number;
132
+ static names(): { [key: string]: string } {
133
+ return {
134
+ inputTokens: 'InputTokens',
135
+ outputTokens: 'OutputTokens',
136
+ tokenMap: 'TokenMap',
137
+ totalTokens: 'TotalTokens',
138
+ };
139
+ }
140
+
141
+ static types(): { [key: string]: any } {
142
+ return {
143
+ inputTokens: 'number',
144
+ outputTokens: 'number',
145
+ tokenMap: { 'type': 'map', 'keyType': 'string', 'valueType': 'number' },
146
+ totalTokens: 'number',
147
+ };
148
+ }
149
+
150
+ validate() {
151
+ if(this.tokenMap) {
152
+ $dara.Model.validateMap(this.tokenMap);
153
+ }
154
+ super.validate();
155
+ }
156
+
157
+ constructor(map?: { [key: string]: any }) {
158
+ super(map);
159
+ }
160
+ }
161
+
162
+ export class RunTopicSelectionMergeResponseBodyPayload extends $dara.Model {
163
+ output?: RunTopicSelectionMergeResponseBodyPayloadOutput;
164
+ usage?: RunTopicSelectionMergeResponseBodyPayloadUsage;
165
+ static names(): { [key: string]: string } {
166
+ return {
167
+ output: 'Output',
168
+ usage: 'Usage',
169
+ };
170
+ }
171
+
172
+ static types(): { [key: string]: any } {
173
+ return {
174
+ output: RunTopicSelectionMergeResponseBodyPayloadOutput,
175
+ usage: RunTopicSelectionMergeResponseBodyPayloadUsage,
176
+ };
177
+ }
178
+
179
+ validate() {
180
+ if(this.output && typeof (this.output as any).validate === 'function') {
181
+ (this.output as any).validate();
182
+ }
183
+ if(this.usage && typeof (this.usage as any).validate === 'function') {
184
+ (this.usage as any).validate();
185
+ }
186
+ super.validate();
187
+ }
188
+
189
+ constructor(map?: { [key: string]: any }) {
190
+ super(map);
191
+ }
192
+ }
193
+
194
+ export class RunTopicSelectionMergeResponseBody extends $dara.Model {
195
+ /**
196
+ * @example
197
+ * true
198
+ */
199
+ end?: boolean;
200
+ header?: RunTopicSelectionMergeResponseBodyHeader;
201
+ payload?: RunTopicSelectionMergeResponseBodyPayload;
202
+ /**
203
+ * @example
204
+ * 3f7045e099474ba28ceca1b4eb6d6e21
205
+ */
206
+ requestId?: string;
207
+ static names(): { [key: string]: string } {
208
+ return {
209
+ end: 'End',
210
+ header: 'Header',
211
+ payload: 'Payload',
212
+ requestId: 'RequestId',
213
+ };
214
+ }
215
+
216
+ static types(): { [key: string]: any } {
217
+ return {
218
+ end: 'boolean',
219
+ header: RunTopicSelectionMergeResponseBodyHeader,
220
+ payload: RunTopicSelectionMergeResponseBodyPayload,
221
+ requestId: 'string',
222
+ };
223
+ }
224
+
225
+ validate() {
226
+ if(this.header && typeof (this.header as any).validate === 'function') {
227
+ (this.header as any).validate();
228
+ }
229
+ if(this.payload && typeof (this.payload as any).validate === 'function') {
230
+ (this.payload as any).validate();
231
+ }
232
+ super.validate();
233
+ }
234
+
235
+ constructor(map?: { [key: string]: any }) {
236
+ super(map);
237
+ }
238
+ }
239
+