@alicloud/quanmiaolightapp20240801 2.9.3 → 2.10.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.
package/dist/client.js CHANGED
@@ -35,6 +35,26 @@ var __importStar = (this && this.__importStar) || (function () {
35
35
  var __exportStar = (this && this.__exportStar) || function(m, exports) {
36
36
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
37
37
  };
38
+ var __await = (this && this.__await) || function (v) { return this instanceof __await ? (this.v = v, this) : new __await(v); }
39
+ var __asyncValues = (this && this.__asyncValues) || function (o) {
40
+ if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
41
+ var m = o[Symbol.asyncIterator], i;
42
+ return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
43
+ function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
44
+ function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
45
+ };
46
+ var __asyncGenerator = (this && this.__asyncGenerator) || function (thisArg, _arguments, generator) {
47
+ if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
48
+ var g = generator.apply(thisArg, _arguments || []), i, q = [];
49
+ return i = Object.create((typeof AsyncIterator === "function" ? AsyncIterator : Object).prototype), verb("next"), verb("throw"), verb("return", awaitReturn), i[Symbol.asyncIterator] = function () { return this; }, i;
50
+ function awaitReturn(f) { return function (v) { return Promise.resolve(v).then(f, reject); }; }
51
+ function verb(n, f) { if (g[n]) { i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; if (f) i[n] = f(i[n]); } }
52
+ function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
53
+ function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
54
+ function fulfill(value) { resume("next", value); }
55
+ function reject(value) { resume("throw", value); }
56
+ function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
57
+ };
38
58
  var __importDefault = (this && this.__importDefault) || function (mod) {
39
59
  return (mod && mod.__esModule) ? mod : { "default": mod };
40
60
  };
@@ -341,6 +361,48 @@ class Client extends openapi_core_1.default {
341
361
  let headers = {};
342
362
  return await this.getEssayCorrectionTaskWithOptions(workspaceId, request, headers, runtime);
343
363
  }
364
+ /**
365
+ * 获取文件内容
366
+ *
367
+ * @param request - GetFileContentRequest
368
+ * @param headers - map
369
+ * @param runtime - runtime options for this request RuntimeOptions
370
+ * @returns GetFileContentResponse
371
+ */
372
+ async getFileContentWithOptions(workspaceId, request, headers, runtime) {
373
+ request.validate();
374
+ let body = {};
375
+ if (!$dara.isNull(request.fileKey)) {
376
+ body["fileKey"] = request.fileKey;
377
+ }
378
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
379
+ headers: headers,
380
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
381
+ });
382
+ let params = new openapi_core_2.$OpenApiUtil.Params({
383
+ action: "GetFileContent",
384
+ version: "2024-08-01",
385
+ protocol: "HTTPS",
386
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/getFileContent`,
387
+ method: "POST",
388
+ authType: "AK",
389
+ style: "ROA",
390
+ reqBodyType: "formData",
391
+ bodyType: "json",
392
+ });
393
+ return $dara.cast(await this.callApi(params, req, runtime), new $_model.GetFileContentResponse({}));
394
+ }
395
+ /**
396
+ * 获取文件内容
397
+ *
398
+ * @param request - GetFileContentRequest
399
+ * @returns GetFileContentResponse
400
+ */
401
+ async getFileContent(workspaceId, request) {
402
+ let runtime = new $dara.RuntimeOptions({});
403
+ let headers = {};
404
+ return await this.getFileContentWithOptions(workspaceId, request, headers, runtime);
405
+ }
344
406
  /**
345
407
  * 获取挖掘分析任务结果
346
408
  *
@@ -602,6 +664,95 @@ class Client extends openapi_core_1.default {
602
664
  let headers = {};
603
665
  return await this.listHotTopicSummariesWithOptions(workspaceId, request, headers, runtime);
604
666
  }
667
+ /**
668
+ * 企业VOC分析
669
+ *
670
+ * @param tmpReq - RunEnterpriseVocAnalysisRequest
671
+ * @param headers - map
672
+ * @param runtime - runtime options for this request RuntimeOptions
673
+ * @returns RunEnterpriseVocAnalysisResponse
674
+ */
675
+ runEnterpriseVocAnalysisWithSSE(workspaceId, tmpReq, headers, runtime) {
676
+ return __asyncGenerator(this, arguments, function* runEnterpriseVocAnalysisWithSSE_1() {
677
+ var _a, e_1, _b, _c;
678
+ tmpReq.validate();
679
+ let request = new $_model.RunEnterpriseVocAnalysisShrinkRequest({});
680
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
681
+ if (!$dara.isNull(tmpReq.filterTags)) {
682
+ request.filterTagsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.filterTags, "filterTags", "json");
683
+ }
684
+ if (!$dara.isNull(tmpReq.tags)) {
685
+ request.tagsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.tags, "tags", "json");
686
+ }
687
+ let body = {};
688
+ if (!$dara.isNull(request.akProxy)) {
689
+ body["akProxy"] = request.akProxy;
690
+ }
691
+ if (!$dara.isNull(request.apiKey)) {
692
+ body["apiKey"] = request.apiKey;
693
+ }
694
+ if (!$dara.isNull(request.content)) {
695
+ body["content"] = request.content;
696
+ }
697
+ if (!$dara.isNull(request.extraInfo)) {
698
+ body["extraInfo"] = request.extraInfo;
699
+ }
700
+ if (!$dara.isNull(request.filterTagsShrink)) {
701
+ body["filterTags"] = request.filterTagsShrink;
702
+ }
703
+ if (!$dara.isNull(request.modelId)) {
704
+ body["modelId"] = request.modelId;
705
+ }
706
+ if (!$dara.isNull(request.outputFormat)) {
707
+ body["outputFormat"] = request.outputFormat;
708
+ }
709
+ if (!$dara.isNull(request.sourceTrace)) {
710
+ body["sourceTrace"] = request.sourceTrace;
711
+ }
712
+ if (!$dara.isNull(request.tagsShrink)) {
713
+ body["tags"] = request.tagsShrink;
714
+ }
715
+ if (!$dara.isNull(request.taskDescription)) {
716
+ body["taskDescription"] = request.taskDescription;
717
+ }
718
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
719
+ headers: headers,
720
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
721
+ });
722
+ let params = new openapi_core_2.$OpenApiUtil.Params({
723
+ action: "RunEnterpriseVocAnalysis",
724
+ version: "2024-08-01",
725
+ protocol: "HTTPS",
726
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runEnterpriseVocAnalysis`,
727
+ method: "POST",
728
+ authType: "AK",
729
+ style: "ROA",
730
+ reqBodyType: "formData",
731
+ bodyType: "json",
732
+ });
733
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
734
+ try {
735
+ for (var _d = true, sseResp_1 = __asyncValues(sseResp), sseResp_1_1; sseResp_1_1 = yield __await(sseResp_1.next()), _a = sseResp_1_1.done, !_a; _d = true) {
736
+ _c = sseResp_1_1.value;
737
+ _d = false;
738
+ let resp = _c;
739
+ let data = JSON.parse(resp.event.data);
740
+ yield yield __await($dara.cast({
741
+ statusCode: resp.statusCode,
742
+ headers: resp.headers,
743
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
744
+ }, new $_model.RunEnterpriseVocAnalysisResponse({})));
745
+ }
746
+ }
747
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
748
+ finally {
749
+ try {
750
+ if (!_d && !_a && (_b = sseResp_1.return)) yield __await(_b.call(sseResp_1));
751
+ }
752
+ finally { if (e_1) throw e_1.error; }
753
+ }
754
+ });
755
+ }
605
756
  /**
606
757
  * 企业VOC分析
607
758
  *
@@ -679,6 +830,78 @@ class Client extends openapi_core_1.default {
679
830
  let headers = {};
680
831
  return await this.runEnterpriseVocAnalysisWithOptions(workspaceId, request, headers, runtime);
681
832
  }
833
+ /**
834
+ * 作业批改
835
+ *
836
+ * @param request - RunEssayCorrectionRequest
837
+ * @param headers - map
838
+ * @param runtime - runtime options for this request RuntimeOptions
839
+ * @returns RunEssayCorrectionResponse
840
+ */
841
+ runEssayCorrectionWithSSE(workspaceId, request, headers, runtime) {
842
+ return __asyncGenerator(this, arguments, function* runEssayCorrectionWithSSE_1() {
843
+ var _a, e_2, _b, _c;
844
+ request.validate();
845
+ let body = {};
846
+ if (!$dara.isNull(request.answer)) {
847
+ body["answer"] = request.answer;
848
+ }
849
+ if (!$dara.isNull(request.grade)) {
850
+ body["grade"] = request.grade;
851
+ }
852
+ if (!$dara.isNull(request.modelId)) {
853
+ body["modelId"] = request.modelId;
854
+ }
855
+ if (!$dara.isNull(request.otherReviewPoints)) {
856
+ body["otherReviewPoints"] = request.otherReviewPoints;
857
+ }
858
+ if (!$dara.isNull(request.question)) {
859
+ body["question"] = request.question;
860
+ }
861
+ if (!$dara.isNull(request.subject)) {
862
+ body["subject"] = request.subject;
863
+ }
864
+ if (!$dara.isNull(request.totalScore)) {
865
+ body["totalScore"] = request.totalScore;
866
+ }
867
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
868
+ headers: headers,
869
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
870
+ });
871
+ let params = new openapi_core_2.$OpenApiUtil.Params({
872
+ action: "RunEssayCorrection",
873
+ version: "2024-08-01",
874
+ protocol: "HTTPS",
875
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runEssayCorrection`,
876
+ method: "POST",
877
+ authType: "AK",
878
+ style: "ROA",
879
+ reqBodyType: "formData",
880
+ bodyType: "json",
881
+ });
882
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
883
+ try {
884
+ for (var _d = true, sseResp_2 = __asyncValues(sseResp), sseResp_2_1; sseResp_2_1 = yield __await(sseResp_2.next()), _a = sseResp_2_1.done, !_a; _d = true) {
885
+ _c = sseResp_2_1.value;
886
+ _d = false;
887
+ let resp = _c;
888
+ let data = JSON.parse(resp.event.data);
889
+ yield yield __await($dara.cast({
890
+ statusCode: resp.statusCode,
891
+ headers: resp.headers,
892
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
893
+ }, new $_model.RunEssayCorrectionResponse({})));
894
+ }
895
+ }
896
+ catch (e_2_1) { e_2 = { error: e_2_1 }; }
897
+ finally {
898
+ try {
899
+ if (!_d && !_a && (_b = sseResp_2.return)) yield __await(_b.call(sseResp_2));
900
+ }
901
+ finally { if (e_2) throw e_2.error; }
902
+ }
903
+ });
904
+ }
682
905
  /**
683
906
  * 作业批改
684
907
  *
@@ -739,6 +962,107 @@ class Client extends openapi_core_1.default {
739
962
  let headers = {};
740
963
  return await this.runEssayCorrectionWithOptions(workspaceId, request, headers, runtime);
741
964
  }
965
+ /**
966
+ * 轻应用-热点播报-问答
967
+ *
968
+ * @param tmpReq - RunHotTopicChatRequest
969
+ * @param headers - map
970
+ * @param runtime - runtime options for this request RuntimeOptions
971
+ * @returns RunHotTopicChatResponse
972
+ */
973
+ runHotTopicChatWithSSE(workspaceId, tmpReq, headers, runtime) {
974
+ return __asyncGenerator(this, arguments, function* runHotTopicChatWithSSE_1() {
975
+ var _a, e_3, _b, _c;
976
+ tmpReq.validate();
977
+ let request = new $_model.RunHotTopicChatShrinkRequest({});
978
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
979
+ if (!$dara.isNull(tmpReq.generateOptions)) {
980
+ request.generateOptionsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.generateOptions, "generateOptions", "json");
981
+ }
982
+ if (!$dara.isNull(tmpReq.hotTopics)) {
983
+ request.hotTopicsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.hotTopics, "hotTopics", "json");
984
+ }
985
+ if (!$dara.isNull(tmpReq.messages)) {
986
+ request.messagesShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.messages, "messages", "json");
987
+ }
988
+ if (!$dara.isNull(tmpReq.stepForBroadcastContentConfig)) {
989
+ request.stepForBroadcastContentConfigShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.stepForBroadcastContentConfig, "stepForBroadcastContentConfig", "json");
990
+ }
991
+ let body = {};
992
+ if (!$dara.isNull(request.category)) {
993
+ body["category"] = request.category;
994
+ }
995
+ if (!$dara.isNull(request.generateOptionsShrink)) {
996
+ body["generateOptions"] = request.generateOptionsShrink;
997
+ }
998
+ if (!$dara.isNull(request.hotTopicVersion)) {
999
+ body["hotTopicVersion"] = request.hotTopicVersion;
1000
+ }
1001
+ if (!$dara.isNull(request.hotTopicsShrink)) {
1002
+ body["hotTopics"] = request.hotTopicsShrink;
1003
+ }
1004
+ if (!$dara.isNull(request.imageCount)) {
1005
+ body["imageCount"] = request.imageCount;
1006
+ }
1007
+ if (!$dara.isNull(request.messagesShrink)) {
1008
+ body["messages"] = request.messagesShrink;
1009
+ }
1010
+ if (!$dara.isNull(request.modelCustomPromptTemplate)) {
1011
+ body["modelCustomPromptTemplate"] = request.modelCustomPromptTemplate;
1012
+ }
1013
+ if (!$dara.isNull(request.modelId)) {
1014
+ body["modelId"] = request.modelId;
1015
+ }
1016
+ if (!$dara.isNull(request.originalSessionId)) {
1017
+ body["originalSessionId"] = request.originalSessionId;
1018
+ }
1019
+ if (!$dara.isNull(request.prompt)) {
1020
+ body["prompt"] = request.prompt;
1021
+ }
1022
+ if (!$dara.isNull(request.stepForBroadcastContentConfigShrink)) {
1023
+ body["stepForBroadcastContentConfig"] = request.stepForBroadcastContentConfigShrink;
1024
+ }
1025
+ if (!$dara.isNull(request.taskId)) {
1026
+ body["taskId"] = request.taskId;
1027
+ }
1028
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1029
+ headers: headers,
1030
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1031
+ });
1032
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1033
+ action: "RunHotTopicChat",
1034
+ version: "2024-08-01",
1035
+ protocol: "HTTPS",
1036
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runHotTopicChat`,
1037
+ method: "POST",
1038
+ authType: "AK",
1039
+ style: "ROA",
1040
+ reqBodyType: "formData",
1041
+ bodyType: "json",
1042
+ });
1043
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
1044
+ try {
1045
+ for (var _d = true, sseResp_3 = __asyncValues(sseResp), sseResp_3_1; sseResp_3_1 = yield __await(sseResp_3.next()), _a = sseResp_3_1.done, !_a; _d = true) {
1046
+ _c = sseResp_3_1.value;
1047
+ _d = false;
1048
+ let resp = _c;
1049
+ let data = JSON.parse(resp.event.data);
1050
+ yield yield __await($dara.cast({
1051
+ statusCode: resp.statusCode,
1052
+ headers: resp.headers,
1053
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
1054
+ }, new $_model.RunHotTopicChatResponse({})));
1055
+ }
1056
+ }
1057
+ catch (e_3_1) { e_3 = { error: e_3_1 }; }
1058
+ finally {
1059
+ try {
1060
+ if (!_d && !_a && (_b = sseResp_3.return)) yield __await(_b.call(sseResp_3));
1061
+ }
1062
+ finally { if (e_3) throw e_3.error; }
1063
+ }
1064
+ });
1065
+ }
742
1066
  /**
743
1067
  * 轻应用-热点播报-问答
744
1068
  *
@@ -828,6 +1152,74 @@ class Client extends openapi_core_1.default {
828
1152
  let headers = {};
829
1153
  return await this.runHotTopicChatWithOptions(workspaceId, request, headers, runtime);
830
1154
  }
1155
+ /**
1156
+ * 轻应用-热点播报-热点摘要生成
1157
+ *
1158
+ * @param tmpReq - RunHotTopicSummaryRequest
1159
+ * @param headers - map
1160
+ * @param runtime - runtime options for this request RuntimeOptions
1161
+ * @returns RunHotTopicSummaryResponse
1162
+ */
1163
+ runHotTopicSummaryWithSSE(workspaceId, tmpReq, headers, runtime) {
1164
+ return __asyncGenerator(this, arguments, function* runHotTopicSummaryWithSSE_1() {
1165
+ var _a, e_4, _b, _c;
1166
+ tmpReq.validate();
1167
+ let request = new $_model.RunHotTopicSummaryShrinkRequest({});
1168
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
1169
+ if (!$dara.isNull(tmpReq.stepForCustomSummaryStyleConfig)) {
1170
+ request.stepForCustomSummaryStyleConfigShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.stepForCustomSummaryStyleConfig, "stepForCustomSummaryStyleConfig", "json");
1171
+ }
1172
+ if (!$dara.isNull(tmpReq.topicIds)) {
1173
+ request.topicIdsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.topicIds, "topicIds", "json");
1174
+ }
1175
+ let body = {};
1176
+ if (!$dara.isNull(request.hotTopicVersion)) {
1177
+ body["hotTopicVersion"] = request.hotTopicVersion;
1178
+ }
1179
+ if (!$dara.isNull(request.stepForCustomSummaryStyleConfigShrink)) {
1180
+ body["stepForCustomSummaryStyleConfig"] = request.stepForCustomSummaryStyleConfigShrink;
1181
+ }
1182
+ if (!$dara.isNull(request.topicIdsShrink)) {
1183
+ body["topicIds"] = request.topicIdsShrink;
1184
+ }
1185
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1186
+ headers: headers,
1187
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1188
+ });
1189
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1190
+ action: "RunHotTopicSummary",
1191
+ version: "2024-08-01",
1192
+ protocol: "HTTPS",
1193
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runHotTopicSummary`,
1194
+ method: "POST",
1195
+ authType: "AK",
1196
+ style: "ROA",
1197
+ reqBodyType: "formData",
1198
+ bodyType: "json",
1199
+ });
1200
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
1201
+ try {
1202
+ for (var _d = true, sseResp_4 = __asyncValues(sseResp), sseResp_4_1; sseResp_4_1 = yield __await(sseResp_4.next()), _a = sseResp_4_1.done, !_a; _d = true) {
1203
+ _c = sseResp_4_1.value;
1204
+ _d = false;
1205
+ let resp = _c;
1206
+ let data = JSON.parse(resp.event.data);
1207
+ yield yield __await($dara.cast({
1208
+ statusCode: resp.statusCode,
1209
+ headers: resp.headers,
1210
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
1211
+ }, new $_model.RunHotTopicSummaryResponse({})));
1212
+ }
1213
+ }
1214
+ catch (e_4_1) { e_4 = { error: e_4_1 }; }
1215
+ finally {
1216
+ try {
1217
+ if (!_d && !_a && (_b = sseResp_4.return)) yield __await(_b.call(sseResp_4));
1218
+ }
1219
+ finally { if (e_4) throw e_4.error; }
1220
+ }
1221
+ });
1222
+ }
831
1223
  /**
832
1224
  * 轻应用-热点播报-热点摘要生成
833
1225
  *
@@ -884,6 +1276,74 @@ class Client extends openapi_core_1.default {
884
1276
  let headers = {};
885
1277
  return await this.runHotTopicSummaryWithOptions(workspaceId, request, headers, runtime);
886
1278
  }
1279
+ /**
1280
+ * 营销信息抽取服务
1281
+ *
1282
+ * @param tmpReq - RunMarketingInformationExtractRequest
1283
+ * @param headers - map
1284
+ * @param runtime - runtime options for this request RuntimeOptions
1285
+ * @returns RunMarketingInformationExtractResponse
1286
+ */
1287
+ runMarketingInformationExtractWithSSE(workspaceId, tmpReq, headers, runtime) {
1288
+ return __asyncGenerator(this, arguments, function* runMarketingInformationExtractWithSSE_1() {
1289
+ var _a, e_5, _b, _c;
1290
+ tmpReq.validate();
1291
+ let request = new $_model.RunMarketingInformationExtractShrinkRequest({});
1292
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
1293
+ if (!$dara.isNull(tmpReq.sourceMaterials)) {
1294
+ request.sourceMaterialsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.sourceMaterials, "sourceMaterials", "json");
1295
+ }
1296
+ let body = {};
1297
+ if (!$dara.isNull(request.customPrompt)) {
1298
+ body["customPrompt"] = request.customPrompt;
1299
+ }
1300
+ if (!$dara.isNull(request.extractType)) {
1301
+ body["extractType"] = request.extractType;
1302
+ }
1303
+ if (!$dara.isNull(request.modelId)) {
1304
+ body["modelId"] = request.modelId;
1305
+ }
1306
+ if (!$dara.isNull(request.sourceMaterialsShrink)) {
1307
+ body["sourceMaterials"] = request.sourceMaterialsShrink;
1308
+ }
1309
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1310
+ headers: headers,
1311
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1312
+ });
1313
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1314
+ action: "RunMarketingInformationExtract",
1315
+ version: "2024-08-01",
1316
+ protocol: "HTTPS",
1317
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runMarketingInformationExtract`,
1318
+ method: "POST",
1319
+ authType: "AK",
1320
+ style: "ROA",
1321
+ reqBodyType: "formData",
1322
+ bodyType: "json",
1323
+ });
1324
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
1325
+ try {
1326
+ for (var _d = true, sseResp_5 = __asyncValues(sseResp), sseResp_5_1; sseResp_5_1 = yield __await(sseResp_5.next()), _a = sseResp_5_1.done, !_a; _d = true) {
1327
+ _c = sseResp_5_1.value;
1328
+ _d = false;
1329
+ let resp = _c;
1330
+ let data = JSON.parse(resp.event.data);
1331
+ yield yield __await($dara.cast({
1332
+ statusCode: resp.statusCode,
1333
+ headers: resp.headers,
1334
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
1335
+ }, new $_model.RunMarketingInformationExtractResponse({})));
1336
+ }
1337
+ }
1338
+ catch (e_5_1) { e_5 = { error: e_5_1 }; }
1339
+ finally {
1340
+ try {
1341
+ if (!_d && !_a && (_b = sseResp_5.return)) yield __await(_b.call(sseResp_5));
1342
+ }
1343
+ finally { if (e_5) throw e_5.error; }
1344
+ }
1345
+ });
1346
+ }
887
1347
  /**
888
1348
  * 营销信息抽取服务
889
1349
  *
@@ -940,6 +1400,81 @@ class Client extends openapi_core_1.default {
940
1400
  let headers = {};
941
1401
  return await this.runMarketingInformationExtractWithOptions(workspaceId, request, headers, runtime);
942
1402
  }
1403
+ /**
1404
+ * 营销文案写作服务
1405
+ *
1406
+ * @param request - RunMarketingInformationWritingRequest
1407
+ * @param headers - map
1408
+ * @param runtime - runtime options for this request RuntimeOptions
1409
+ * @returns RunMarketingInformationWritingResponse
1410
+ */
1411
+ runMarketingInformationWritingWithSSE(workspaceId, request, headers, runtime) {
1412
+ return __asyncGenerator(this, arguments, function* runMarketingInformationWritingWithSSE_1() {
1413
+ var _a, e_6, _b, _c;
1414
+ request.validate();
1415
+ let body = {};
1416
+ if (!$dara.isNull(request.apiKey)) {
1417
+ body["apiKey"] = request.apiKey;
1418
+ }
1419
+ if (!$dara.isNull(request.customLimitation)) {
1420
+ body["customLimitation"] = request.customLimitation;
1421
+ }
1422
+ if (!$dara.isNull(request.customPrompt)) {
1423
+ body["customPrompt"] = request.customPrompt;
1424
+ }
1425
+ if (!$dara.isNull(request.inputExample)) {
1426
+ body["inputExample"] = request.inputExample;
1427
+ }
1428
+ if (!$dara.isNull(request.modelId)) {
1429
+ body["modelId"] = request.modelId;
1430
+ }
1431
+ if (!$dara.isNull(request.outputExample)) {
1432
+ body["outputExample"] = request.outputExample;
1433
+ }
1434
+ if (!$dara.isNull(request.sourceMaterial)) {
1435
+ body["sourceMaterial"] = request.sourceMaterial;
1436
+ }
1437
+ if (!$dara.isNull(request.writingType)) {
1438
+ body["writingType"] = request.writingType;
1439
+ }
1440
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1441
+ headers: headers,
1442
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1443
+ });
1444
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1445
+ action: "RunMarketingInformationWriting",
1446
+ version: "2024-08-01",
1447
+ protocol: "HTTPS",
1448
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runMarketingInformationWriting`,
1449
+ method: "POST",
1450
+ authType: "AK",
1451
+ style: "ROA",
1452
+ reqBodyType: "formData",
1453
+ bodyType: "json",
1454
+ });
1455
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
1456
+ try {
1457
+ for (var _d = true, sseResp_6 = __asyncValues(sseResp), sseResp_6_1; sseResp_6_1 = yield __await(sseResp_6.next()), _a = sseResp_6_1.done, !_a; _d = true) {
1458
+ _c = sseResp_6_1.value;
1459
+ _d = false;
1460
+ let resp = _c;
1461
+ let data = JSON.parse(resp.event.data);
1462
+ yield yield __await($dara.cast({
1463
+ statusCode: resp.statusCode,
1464
+ headers: resp.headers,
1465
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
1466
+ }, new $_model.RunMarketingInformationWritingResponse({})));
1467
+ }
1468
+ }
1469
+ catch (e_6_1) { e_6 = { error: e_6_1 }; }
1470
+ finally {
1471
+ try {
1472
+ if (!_d && !_a && (_b = sseResp_6.return)) yield __await(_b.call(sseResp_6));
1473
+ }
1474
+ finally { if (e_6) throw e_6.error; }
1475
+ }
1476
+ });
1477
+ }
943
1478
  /**
944
1479
  * 营销文案写作服务
945
1480
  *
@@ -1003,6 +1538,86 @@ class Client extends openapi_core_1.default {
1003
1538
  let headers = {};
1004
1539
  return await this.runMarketingInformationWritingWithOptions(workspaceId, request, headers, runtime);
1005
1540
  }
1541
+ /**
1542
+ * 轻应用-网络内容审核
1543
+ *
1544
+ * @param tmpReq - RunNetworkContentAuditRequest
1545
+ * @param headers - map
1546
+ * @param runtime - runtime options for this request RuntimeOptions
1547
+ * @returns RunNetworkContentAuditResponse
1548
+ */
1549
+ runNetworkContentAuditWithSSE(workspaceId, tmpReq, headers, runtime) {
1550
+ return __asyncGenerator(this, arguments, function* runNetworkContentAuditWithSSE_1() {
1551
+ var _a, e_7, _b, _c;
1552
+ tmpReq.validate();
1553
+ let request = new $_model.RunNetworkContentAuditShrinkRequest({});
1554
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
1555
+ if (!$dara.isNull(tmpReq.tags)) {
1556
+ request.tagsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.tags, "tags", "json");
1557
+ }
1558
+ let body = {};
1559
+ if (!$dara.isNull(request.apiKey)) {
1560
+ body["apiKey"] = request.apiKey;
1561
+ }
1562
+ if (!$dara.isNull(request.businessType)) {
1563
+ body["businessType"] = request.businessType;
1564
+ }
1565
+ if (!$dara.isNull(request.content)) {
1566
+ body["content"] = request.content;
1567
+ }
1568
+ if (!$dara.isNull(request.extraInfo)) {
1569
+ body["extraInfo"] = request.extraInfo;
1570
+ }
1571
+ if (!$dara.isNull(request.modelId)) {
1572
+ body["modelId"] = request.modelId;
1573
+ }
1574
+ if (!$dara.isNull(request.outputFormat)) {
1575
+ body["outputFormat"] = request.outputFormat;
1576
+ }
1577
+ if (!$dara.isNull(request.tagsShrink)) {
1578
+ body["tags"] = request.tagsShrink;
1579
+ }
1580
+ if (!$dara.isNull(request.taskDescription)) {
1581
+ body["taskDescription"] = request.taskDescription;
1582
+ }
1583
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1584
+ headers: headers,
1585
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1586
+ });
1587
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1588
+ action: "RunNetworkContentAudit",
1589
+ version: "2024-08-01",
1590
+ protocol: "HTTPS",
1591
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runNetworkContentAudit`,
1592
+ method: "POST",
1593
+ authType: "AK",
1594
+ style: "ROA",
1595
+ reqBodyType: "formData",
1596
+ bodyType: "json",
1597
+ });
1598
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
1599
+ try {
1600
+ for (var _d = true, sseResp_7 = __asyncValues(sseResp), sseResp_7_1; sseResp_7_1 = yield __await(sseResp_7.next()), _a = sseResp_7_1.done, !_a; _d = true) {
1601
+ _c = sseResp_7_1.value;
1602
+ _d = false;
1603
+ let resp = _c;
1604
+ let data = JSON.parse(resp.event.data);
1605
+ yield yield __await($dara.cast({
1606
+ statusCode: resp.statusCode,
1607
+ headers: resp.headers,
1608
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
1609
+ }, new $_model.RunNetworkContentAuditResponse({})));
1610
+ }
1611
+ }
1612
+ catch (e_7_1) { e_7 = { error: e_7_1 }; }
1613
+ finally {
1614
+ try {
1615
+ if (!_d && !_a && (_b = sseResp_7.return)) yield __await(_b.call(sseResp_7));
1616
+ }
1617
+ finally { if (e_7) throw e_7.error; }
1618
+ }
1619
+ });
1620
+ }
1006
1621
  /**
1007
1622
  * 轻应用-网络内容审核
1008
1623
  *
@@ -1071,6 +1686,66 @@ class Client extends openapi_core_1.default {
1071
1686
  let headers = {};
1072
1687
  return await this.runNetworkContentAuditWithOptions(workspaceId, request, headers, runtime);
1073
1688
  }
1689
+ /**
1690
+ * 作业批改
1691
+ *
1692
+ * @param request - RunOcrParseRequest
1693
+ * @param headers - map
1694
+ * @param runtime - runtime options for this request RuntimeOptions
1695
+ * @returns RunOcrParseResponse
1696
+ */
1697
+ runOcrParseWithSSE(workspaceId, request, headers, runtime) {
1698
+ return __asyncGenerator(this, arguments, function* runOcrParseWithSSE_1() {
1699
+ var _a, e_8, _b, _c;
1700
+ request.validate();
1701
+ let body = {};
1702
+ if (!$dara.isNull(request.fileKey)) {
1703
+ body["fileKey"] = request.fileKey;
1704
+ }
1705
+ if (!$dara.isNull(request.modelId)) {
1706
+ body["modelId"] = request.modelId;
1707
+ }
1708
+ if (!$dara.isNull(request.url)) {
1709
+ body["url"] = request.url;
1710
+ }
1711
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1712
+ headers: headers,
1713
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1714
+ });
1715
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1716
+ action: "RunOcrParse",
1717
+ version: "2024-08-01",
1718
+ protocol: "HTTPS",
1719
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runOcrParse`,
1720
+ method: "POST",
1721
+ authType: "AK",
1722
+ style: "ROA",
1723
+ reqBodyType: "formData",
1724
+ bodyType: "json",
1725
+ });
1726
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
1727
+ try {
1728
+ for (var _d = true, sseResp_8 = __asyncValues(sseResp), sseResp_8_1; sseResp_8_1 = yield __await(sseResp_8.next()), _a = sseResp_8_1.done, !_a; _d = true) {
1729
+ _c = sseResp_8_1.value;
1730
+ _d = false;
1731
+ let resp = _c;
1732
+ let data = JSON.parse(resp.event.data);
1733
+ yield yield __await($dara.cast({
1734
+ statusCode: resp.statusCode,
1735
+ headers: resp.headers,
1736
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
1737
+ }, new $_model.RunOcrParseResponse({})));
1738
+ }
1739
+ }
1740
+ catch (e_8_1) { e_8 = { error: e_8_1 }; }
1741
+ finally {
1742
+ try {
1743
+ if (!_d && !_a && (_b = sseResp_8.return)) yield __await(_b.call(sseResp_8));
1744
+ }
1745
+ finally { if (e_8) throw e_8.error; }
1746
+ }
1747
+ });
1748
+ }
1074
1749
  /**
1075
1750
  * 作业批改
1076
1751
  *
@@ -1119,6 +1794,63 @@ class Client extends openapi_core_1.default {
1119
1794
  let headers = {};
1120
1795
  return await this.runOcrParseWithOptions(workspaceId, request, headers, runtime);
1121
1796
  }
1797
+ /**
1798
+ * 长剧本创作
1799
+ *
1800
+ * @param request - RunScriptChatRequest
1801
+ * @param headers - map
1802
+ * @param runtime - runtime options for this request RuntimeOptions
1803
+ * @returns RunScriptChatResponse
1804
+ */
1805
+ runScriptChatWithSSE(workspaceId, request, headers, runtime) {
1806
+ return __asyncGenerator(this, arguments, function* runScriptChatWithSSE_1() {
1807
+ var _a, e_9, _b, _c;
1808
+ request.validate();
1809
+ let body = {};
1810
+ if (!$dara.isNull(request.prompt)) {
1811
+ body["prompt"] = request.prompt;
1812
+ }
1813
+ if (!$dara.isNull(request.taskId)) {
1814
+ body["taskId"] = request.taskId;
1815
+ }
1816
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1817
+ headers: headers,
1818
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1819
+ });
1820
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1821
+ action: "RunScriptChat",
1822
+ version: "2024-08-01",
1823
+ protocol: "HTTPS",
1824
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runScriptChat`,
1825
+ method: "POST",
1826
+ authType: "AK",
1827
+ style: "ROA",
1828
+ reqBodyType: "formData",
1829
+ bodyType: "json",
1830
+ });
1831
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
1832
+ try {
1833
+ for (var _d = true, sseResp_9 = __asyncValues(sseResp), sseResp_9_1; sseResp_9_1 = yield __await(sseResp_9.next()), _a = sseResp_9_1.done, !_a; _d = true) {
1834
+ _c = sseResp_9_1.value;
1835
+ _d = false;
1836
+ let resp = _c;
1837
+ let data = JSON.parse(resp.event.data);
1838
+ yield yield __await($dara.cast({
1839
+ statusCode: resp.statusCode,
1840
+ headers: resp.headers,
1841
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
1842
+ }, new $_model.RunScriptChatResponse({})));
1843
+ }
1844
+ }
1845
+ catch (e_9_1) { e_9 = { error: e_9_1 }; }
1846
+ finally {
1847
+ try {
1848
+ if (!_d && !_a && (_b = sseResp_9.return)) yield __await(_b.call(sseResp_9));
1849
+ }
1850
+ finally { if (e_9) throw e_9.error; }
1851
+ }
1852
+ });
1853
+ }
1122
1854
  /**
1123
1855
  * 长剧本创作
1124
1856
  *
@@ -1164,6 +1896,66 @@ class Client extends openapi_core_1.default {
1164
1896
  let headers = {};
1165
1897
  return await this.runScriptChatWithOptions(workspaceId, request, headers, runtime);
1166
1898
  }
1899
+ /**
1900
+ * 剧本续写
1901
+ *
1902
+ * @param request - RunScriptContinueRequest
1903
+ * @param headers - map
1904
+ * @param runtime - runtime options for this request RuntimeOptions
1905
+ * @returns RunScriptContinueResponse
1906
+ */
1907
+ runScriptContinueWithSSE(workspaceId, request, headers, runtime) {
1908
+ return __asyncGenerator(this, arguments, function* runScriptContinueWithSSE_1() {
1909
+ var _a, e_10, _b, _c;
1910
+ request.validate();
1911
+ let body = {};
1912
+ if (!$dara.isNull(request.scriptSummary)) {
1913
+ body["scriptSummary"] = request.scriptSummary;
1914
+ }
1915
+ if (!$dara.isNull(request.scriptTypeKeyword)) {
1916
+ body["scriptTypeKeyword"] = request.scriptTypeKeyword;
1917
+ }
1918
+ if (!$dara.isNull(request.userProvidedContent)) {
1919
+ body["userProvidedContent"] = request.userProvidedContent;
1920
+ }
1921
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1922
+ headers: headers,
1923
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1924
+ });
1925
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1926
+ action: "RunScriptContinue",
1927
+ version: "2024-08-01",
1928
+ protocol: "HTTPS",
1929
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runScriptContinue`,
1930
+ method: "POST",
1931
+ authType: "AK",
1932
+ style: "ROA",
1933
+ reqBodyType: "formData",
1934
+ bodyType: "json",
1935
+ });
1936
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
1937
+ try {
1938
+ for (var _d = true, sseResp_10 = __asyncValues(sseResp), sseResp_10_1; sseResp_10_1 = yield __await(sseResp_10.next()), _a = sseResp_10_1.done, !_a; _d = true) {
1939
+ _c = sseResp_10_1.value;
1940
+ _d = false;
1941
+ let resp = _c;
1942
+ let data = JSON.parse(resp.event.data);
1943
+ yield yield __await($dara.cast({
1944
+ statusCode: resp.statusCode,
1945
+ headers: resp.headers,
1946
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
1947
+ }, new $_model.RunScriptContinueResponse({})));
1948
+ }
1949
+ }
1950
+ catch (e_10_1) { e_10 = { error: e_10_1 }; }
1951
+ finally {
1952
+ try {
1953
+ if (!_d && !_a && (_b = sseResp_10.return)) yield __await(_b.call(sseResp_10));
1954
+ }
1955
+ finally { if (e_10) throw e_10.error; }
1956
+ }
1957
+ });
1958
+ }
1167
1959
  /**
1168
1960
  * 剧本续写
1169
1961
  *
@@ -1212,6 +2004,78 @@ class Client extends openapi_core_1.default {
1212
2004
  let headers = {};
1213
2005
  return await this.runScriptContinueWithOptions(workspaceId, request, headers, runtime);
1214
2006
  }
2007
+ /**
2008
+ * 剧本策划
2009
+ *
2010
+ * @param request - RunScriptPlanningRequest
2011
+ * @param headers - map
2012
+ * @param runtime - runtime options for this request RuntimeOptions
2013
+ * @returns RunScriptPlanningResponse
2014
+ */
2015
+ runScriptPlanningWithSSE(workspaceId, request, headers, runtime) {
2016
+ return __asyncGenerator(this, arguments, function* runScriptPlanningWithSSE_1() {
2017
+ var _a, e_11, _b, _c;
2018
+ request.validate();
2019
+ let body = {};
2020
+ if (!$dara.isNull(request.additionalNote)) {
2021
+ body["additionalNote"] = request.additionalNote;
2022
+ }
2023
+ if (!$dara.isNull(request.dialogueInScene)) {
2024
+ body["dialogueInScene"] = request.dialogueInScene;
2025
+ }
2026
+ if (!$dara.isNull(request.plotConflict)) {
2027
+ body["plotConflict"] = request.plotConflict;
2028
+ }
2029
+ if (!$dara.isNull(request.scriptName)) {
2030
+ body["scriptName"] = request.scriptName;
2031
+ }
2032
+ if (!$dara.isNull(request.scriptShotCount)) {
2033
+ body["scriptShotCount"] = request.scriptShotCount;
2034
+ }
2035
+ if (!$dara.isNull(request.scriptSummary)) {
2036
+ body["scriptSummary"] = request.scriptSummary;
2037
+ }
2038
+ if (!$dara.isNull(request.scriptTypeKeyword)) {
2039
+ body["scriptTypeKeyword"] = request.scriptTypeKeyword;
2040
+ }
2041
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
2042
+ headers: headers,
2043
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
2044
+ });
2045
+ let params = new openapi_core_2.$OpenApiUtil.Params({
2046
+ action: "RunScriptPlanning",
2047
+ version: "2024-08-01",
2048
+ protocol: "HTTPS",
2049
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runScriptPlanning`,
2050
+ method: "POST",
2051
+ authType: "AK",
2052
+ style: "ROA",
2053
+ reqBodyType: "formData",
2054
+ bodyType: "json",
2055
+ });
2056
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
2057
+ try {
2058
+ for (var _d = true, sseResp_11 = __asyncValues(sseResp), sseResp_11_1; sseResp_11_1 = yield __await(sseResp_11.next()), _a = sseResp_11_1.done, !_a; _d = true) {
2059
+ _c = sseResp_11_1.value;
2060
+ _d = false;
2061
+ let resp = _c;
2062
+ let data = JSON.parse(resp.event.data);
2063
+ yield yield __await($dara.cast({
2064
+ statusCode: resp.statusCode,
2065
+ headers: resp.headers,
2066
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
2067
+ }, new $_model.RunScriptPlanningResponse({})));
2068
+ }
2069
+ }
2070
+ catch (e_11_1) { e_11 = { error: e_11_1 }; }
2071
+ finally {
2072
+ try {
2073
+ if (!_d && !_a && (_b = sseResp_11.return)) yield __await(_b.call(sseResp_11));
2074
+ }
2075
+ finally { if (e_11) throw e_11.error; }
2076
+ }
2077
+ });
2078
+ }
1215
2079
  /**
1216
2080
  * 剧本策划
1217
2081
  *
@@ -1272,6 +2136,60 @@ class Client extends openapi_core_1.default {
1272
2136
  let headers = {};
1273
2137
  return await this.runScriptPlanningWithOptions(workspaceId, request, headers, runtime);
1274
2138
  }
2139
+ /**
2140
+ * 剧本对话内容的整理
2141
+ *
2142
+ * @param request - RunScriptRefineRequest
2143
+ * @param headers - map
2144
+ * @param runtime - runtime options for this request RuntimeOptions
2145
+ * @returns RunScriptRefineResponse
2146
+ */
2147
+ runScriptRefineWithSSE(workspaceId, request, headers, runtime) {
2148
+ return __asyncGenerator(this, arguments, function* runScriptRefineWithSSE_1() {
2149
+ var _a, e_12, _b, _c;
2150
+ request.validate();
2151
+ let body = {};
2152
+ if (!$dara.isNull(request.taskId)) {
2153
+ body["taskId"] = request.taskId;
2154
+ }
2155
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
2156
+ headers: headers,
2157
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
2158
+ });
2159
+ let params = new openapi_core_2.$OpenApiUtil.Params({
2160
+ action: "RunScriptRefine",
2161
+ version: "2024-08-01",
2162
+ protocol: "HTTPS",
2163
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runScriptRefine`,
2164
+ method: "POST",
2165
+ authType: "AK",
2166
+ style: "ROA",
2167
+ reqBodyType: "formData",
2168
+ bodyType: "json",
2169
+ });
2170
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
2171
+ try {
2172
+ for (var _d = true, sseResp_12 = __asyncValues(sseResp), sseResp_12_1; sseResp_12_1 = yield __await(sseResp_12.next()), _a = sseResp_12_1.done, !_a; _d = true) {
2173
+ _c = sseResp_12_1.value;
2174
+ _d = false;
2175
+ let resp = _c;
2176
+ let data = JSON.parse(resp.event.data);
2177
+ yield yield __await($dara.cast({
2178
+ statusCode: resp.statusCode,
2179
+ headers: resp.headers,
2180
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
2181
+ }, new $_model.RunScriptRefineResponse({})));
2182
+ }
2183
+ }
2184
+ catch (e_12_1) { e_12 = { error: e_12_1 }; }
2185
+ finally {
2186
+ try {
2187
+ if (!_d && !_a && (_b = sseResp_12.return)) yield __await(_b.call(sseResp_12));
2188
+ }
2189
+ finally { if (e_12) throw e_12.error; }
2190
+ }
2191
+ });
2192
+ }
1275
2193
  /**
1276
2194
  * 剧本对话内容的整理
1277
2195
  *
@@ -1314,6 +2232,83 @@ class Client extends openapi_core_1.default {
1314
2232
  let headers = {};
1315
2233
  return await this.runScriptRefineWithOptions(workspaceId, request, headers, runtime);
1316
2234
  }
2235
+ /**
2236
+ * 文体学习和写作推理服务
2237
+ *
2238
+ * @param tmpReq - RunStyleWritingRequest
2239
+ * @param headers - map
2240
+ * @param runtime - runtime options for this request RuntimeOptions
2241
+ * @returns RunStyleWritingResponse
2242
+ */
2243
+ runStyleWritingWithSSE(workspaceId, tmpReq, headers, runtime) {
2244
+ return __asyncGenerator(this, arguments, function* runStyleWritingWithSSE_1() {
2245
+ var _a, e_13, _b, _c;
2246
+ tmpReq.validate();
2247
+ let request = new $_model.RunStyleWritingShrinkRequest({});
2248
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
2249
+ if (!$dara.isNull(tmpReq.learningSamples)) {
2250
+ request.learningSamplesShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.learningSamples, "learningSamples", "json");
2251
+ }
2252
+ if (!$dara.isNull(tmpReq.referenceMaterials)) {
2253
+ request.referenceMaterialsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.referenceMaterials, "referenceMaterials", "json");
2254
+ }
2255
+ let body = {};
2256
+ if (!$dara.isNull(request.learningSamplesShrink)) {
2257
+ body["learningSamples"] = request.learningSamplesShrink;
2258
+ }
2259
+ if (!$dara.isNull(request.processStage)) {
2260
+ body["processStage"] = request.processStage;
2261
+ }
2262
+ if (!$dara.isNull(request.referenceMaterialsShrink)) {
2263
+ body["referenceMaterials"] = request.referenceMaterialsShrink;
2264
+ }
2265
+ if (!$dara.isNull(request.styleFeature)) {
2266
+ body["styleFeature"] = request.styleFeature;
2267
+ }
2268
+ if (!$dara.isNull(request.useSearch)) {
2269
+ body["useSearch"] = request.useSearch;
2270
+ }
2271
+ if (!$dara.isNull(request.writingTheme)) {
2272
+ body["writingTheme"] = request.writingTheme;
2273
+ }
2274
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
2275
+ headers: headers,
2276
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
2277
+ });
2278
+ let params = new openapi_core_2.$OpenApiUtil.Params({
2279
+ action: "RunStyleWriting",
2280
+ version: "2024-08-01",
2281
+ protocol: "HTTPS",
2282
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runStyleWriting`,
2283
+ method: "POST",
2284
+ authType: "AK",
2285
+ style: "ROA",
2286
+ reqBodyType: "formData",
2287
+ bodyType: "json",
2288
+ });
2289
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
2290
+ try {
2291
+ for (var _d = true, sseResp_13 = __asyncValues(sseResp), sseResp_13_1; sseResp_13_1 = yield __await(sseResp_13.next()), _a = sseResp_13_1.done, !_a; _d = true) {
2292
+ _c = sseResp_13_1.value;
2293
+ _d = false;
2294
+ let resp = _c;
2295
+ let data = JSON.parse(resp.event.data);
2296
+ yield yield __await($dara.cast({
2297
+ statusCode: resp.statusCode,
2298
+ headers: resp.headers,
2299
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
2300
+ }, new $_model.RunStyleWritingResponse({})));
2301
+ }
2302
+ }
2303
+ catch (e_13_1) { e_13 = { error: e_13_1 }; }
2304
+ finally {
2305
+ try {
2306
+ if (!_d && !_a && (_b = sseResp_13.return)) yield __await(_b.call(sseResp_13));
2307
+ }
2308
+ finally { if (e_13) throw e_13.error; }
2309
+ }
2310
+ });
2311
+ }
1317
2312
  /**
1318
2313
  * 文体学习和写作推理服务
1319
2314
  *
@@ -1379,6 +2374,86 @@ class Client extends openapi_core_1.default {
1379
2374
  let headers = {};
1380
2375
  return await this.runStyleWritingWithOptions(workspaceId, request, headers, runtime);
1381
2376
  }
2377
+ /**
2378
+ * 轻应用-标签挖掘
2379
+ *
2380
+ * @param tmpReq - RunTagMiningAnalysisRequest
2381
+ * @param headers - map
2382
+ * @param runtime - runtime options for this request RuntimeOptions
2383
+ * @returns RunTagMiningAnalysisResponse
2384
+ */
2385
+ runTagMiningAnalysisWithSSE(workspaceId, tmpReq, headers, runtime) {
2386
+ return __asyncGenerator(this, arguments, function* runTagMiningAnalysisWithSSE_1() {
2387
+ var _a, e_14, _b, _c;
2388
+ tmpReq.validate();
2389
+ let request = new $_model.RunTagMiningAnalysisShrinkRequest({});
2390
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
2391
+ if (!$dara.isNull(tmpReq.tags)) {
2392
+ request.tagsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.tags, "tags", "json");
2393
+ }
2394
+ let body = {};
2395
+ if (!$dara.isNull(request.apiKey)) {
2396
+ body["apiKey"] = request.apiKey;
2397
+ }
2398
+ if (!$dara.isNull(request.businessType)) {
2399
+ body["businessType"] = request.businessType;
2400
+ }
2401
+ if (!$dara.isNull(request.content)) {
2402
+ body["content"] = request.content;
2403
+ }
2404
+ if (!$dara.isNull(request.extraInfo)) {
2405
+ body["extraInfo"] = request.extraInfo;
2406
+ }
2407
+ if (!$dara.isNull(request.modelId)) {
2408
+ body["modelId"] = request.modelId;
2409
+ }
2410
+ if (!$dara.isNull(request.outputFormat)) {
2411
+ body["outputFormat"] = request.outputFormat;
2412
+ }
2413
+ if (!$dara.isNull(request.tagsShrink)) {
2414
+ body["tags"] = request.tagsShrink;
2415
+ }
2416
+ if (!$dara.isNull(request.taskDescription)) {
2417
+ body["taskDescription"] = request.taskDescription;
2418
+ }
2419
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
2420
+ headers: headers,
2421
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
2422
+ });
2423
+ let params = new openapi_core_2.$OpenApiUtil.Params({
2424
+ action: "RunTagMiningAnalysis",
2425
+ version: "2024-08-01",
2426
+ protocol: "HTTPS",
2427
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runTagMiningAnalysis`,
2428
+ method: "POST",
2429
+ authType: "AK",
2430
+ style: "ROA",
2431
+ reqBodyType: "formData",
2432
+ bodyType: "json",
2433
+ });
2434
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
2435
+ try {
2436
+ for (var _d = true, sseResp_14 = __asyncValues(sseResp), sseResp_14_1; sseResp_14_1 = yield __await(sseResp_14.next()), _a = sseResp_14_1.done, !_a; _d = true) {
2437
+ _c = sseResp_14_1.value;
2438
+ _d = false;
2439
+ let resp = _c;
2440
+ let data = JSON.parse(resp.event.data);
2441
+ yield yield __await($dara.cast({
2442
+ statusCode: resp.statusCode,
2443
+ headers: resp.headers,
2444
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
2445
+ }, new $_model.RunTagMiningAnalysisResponse({})));
2446
+ }
2447
+ }
2448
+ catch (e_14_1) { e_14 = { error: e_14_1 }; }
2449
+ finally {
2450
+ try {
2451
+ if (!_d && !_a && (_b = sseResp_14.return)) yield __await(_b.call(sseResp_14));
2452
+ }
2453
+ finally { if (e_14) throw e_14.error; }
2454
+ }
2455
+ });
2456
+ }
1382
2457
  /**
1383
2458
  * 轻应用-标签挖掘
1384
2459
  *
@@ -1447,6 +2522,140 @@ class Client extends openapi_core_1.default {
1447
2522
  let headers = {};
1448
2523
  return await this.runTagMiningAnalysisWithOptions(workspaceId, request, headers, runtime);
1449
2524
  }
2525
+ /**
2526
+ * 轻应用-视频理解
2527
+ *
2528
+ * @param tmpReq - RunVideoAnalysisRequest
2529
+ * @param headers - map
2530
+ * @param runtime - runtime options for this request RuntimeOptions
2531
+ * @returns RunVideoAnalysisResponse
2532
+ */
2533
+ runVideoAnalysisWithSSE(workspaceId, tmpReq, headers, runtime) {
2534
+ return __asyncGenerator(this, arguments, function* runVideoAnalysisWithSSE_1() {
2535
+ var _a, e_15, _b, _c;
2536
+ tmpReq.validate();
2537
+ let request = new $_model.RunVideoAnalysisShrinkRequest({});
2538
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
2539
+ if (!$dara.isNull(tmpReq.excludeGenerateOptions)) {
2540
+ request.excludeGenerateOptionsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.excludeGenerateOptions, "excludeGenerateOptions", "json");
2541
+ }
2542
+ if (!$dara.isNull(tmpReq.frameSampleMethod)) {
2543
+ request.frameSampleMethodShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.frameSampleMethod, "frameSampleMethod", "json");
2544
+ }
2545
+ if (!$dara.isNull(tmpReq.generateOptions)) {
2546
+ request.generateOptionsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.generateOptions, "generateOptions", "json");
2547
+ }
2548
+ if (!$dara.isNull(tmpReq.textProcessTasks)) {
2549
+ request.textProcessTasksShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.textProcessTasks, "textProcessTasks", "json");
2550
+ }
2551
+ if (!$dara.isNull(tmpReq.videoCaptionInfo)) {
2552
+ request.videoCaptionInfoShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.videoCaptionInfo, "videoCaptionInfo", "json");
2553
+ }
2554
+ if (!$dara.isNull(tmpReq.videoRoles)) {
2555
+ request.videoRolesShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.videoRoles, "videoRoles", "json");
2556
+ }
2557
+ let body = {};
2558
+ if (!$dara.isNull(request.autoRoleRecognitionVideoUrl)) {
2559
+ body["autoRoleRecognitionVideoUrl"] = request.autoRoleRecognitionVideoUrl;
2560
+ }
2561
+ if (!$dara.isNull(request.excludeGenerateOptionsShrink)) {
2562
+ body["excludeGenerateOptions"] = request.excludeGenerateOptionsShrink;
2563
+ }
2564
+ if (!$dara.isNull(request.faceIdentitySimilarityMinScore)) {
2565
+ body["faceIdentitySimilarityMinScore"] = request.faceIdentitySimilarityMinScore;
2566
+ }
2567
+ if (!$dara.isNull(request.frameSampleMethodShrink)) {
2568
+ body["frameSampleMethod"] = request.frameSampleMethodShrink;
2569
+ }
2570
+ if (!$dara.isNull(request.generateOptionsShrink)) {
2571
+ body["generateOptions"] = request.generateOptionsShrink;
2572
+ }
2573
+ if (!$dara.isNull(request.language)) {
2574
+ body["language"] = request.language;
2575
+ }
2576
+ if (!$dara.isNull(request.modelCustomPromptTemplate)) {
2577
+ body["modelCustomPromptTemplate"] = request.modelCustomPromptTemplate;
2578
+ }
2579
+ if (!$dara.isNull(request.modelCustomPromptTemplateId)) {
2580
+ body["modelCustomPromptTemplateId"] = request.modelCustomPromptTemplateId;
2581
+ }
2582
+ if (!$dara.isNull(request.modelId)) {
2583
+ body["modelId"] = request.modelId;
2584
+ }
2585
+ if (!$dara.isNull(request.originalSessionId)) {
2586
+ body["originalSessionId"] = request.originalSessionId;
2587
+ }
2588
+ if (!$dara.isNull(request.snapshotInterval)) {
2589
+ body["snapshotInterval"] = request.snapshotInterval;
2590
+ }
2591
+ if (!$dara.isNull(request.splitInterval)) {
2592
+ body["splitInterval"] = request.splitInterval;
2593
+ }
2594
+ if (!$dara.isNull(request.taskId)) {
2595
+ body["taskId"] = request.taskId;
2596
+ }
2597
+ if (!$dara.isNull(request.textProcessTasksShrink)) {
2598
+ body["textProcessTasks"] = request.textProcessTasksShrink;
2599
+ }
2600
+ if (!$dara.isNull(request.videoCaptionInfoShrink)) {
2601
+ body["videoCaptionInfo"] = request.videoCaptionInfoShrink;
2602
+ }
2603
+ if (!$dara.isNull(request.videoExtraInfo)) {
2604
+ body["videoExtraInfo"] = request.videoExtraInfo;
2605
+ }
2606
+ if (!$dara.isNull(request.videoModelCustomPromptTemplate)) {
2607
+ body["videoModelCustomPromptTemplate"] = request.videoModelCustomPromptTemplate;
2608
+ }
2609
+ if (!$dara.isNull(request.videoModelId)) {
2610
+ body["videoModelId"] = request.videoModelId;
2611
+ }
2612
+ if (!$dara.isNull(request.videoRolesShrink)) {
2613
+ body["videoRoles"] = request.videoRolesShrink;
2614
+ }
2615
+ if (!$dara.isNull(request.videoShotFaceIdentityCount)) {
2616
+ body["videoShotFaceIdentityCount"] = request.videoShotFaceIdentityCount;
2617
+ }
2618
+ if (!$dara.isNull(request.videoUrl)) {
2619
+ body["videoUrl"] = request.videoUrl;
2620
+ }
2621
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
2622
+ headers: headers,
2623
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
2624
+ });
2625
+ let params = new openapi_core_2.$OpenApiUtil.Params({
2626
+ action: "RunVideoAnalysis",
2627
+ version: "2024-08-01",
2628
+ protocol: "HTTPS",
2629
+ pathname: `/${$dara.URL.percentEncode(workspaceId)}/quanmiao/lightapp/runVideoAnalysis`,
2630
+ method: "POST",
2631
+ authType: "AK",
2632
+ style: "ROA",
2633
+ reqBodyType: "formData",
2634
+ bodyType: "json",
2635
+ });
2636
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
2637
+ try {
2638
+ for (var _d = true, sseResp_15 = __asyncValues(sseResp), sseResp_15_1; sseResp_15_1 = yield __await(sseResp_15.next()), _a = sseResp_15_1.done, !_a; _d = true) {
2639
+ _c = sseResp_15_1.value;
2640
+ _d = false;
2641
+ let resp = _c;
2642
+ let data = JSON.parse(resp.event.data);
2643
+ yield yield __await($dara.cast({
2644
+ statusCode: resp.statusCode,
2645
+ headers: resp.headers,
2646
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
2647
+ }, new $_model.RunVideoAnalysisResponse({})));
2648
+ }
2649
+ }
2650
+ catch (e_15_1) { e_15 = { error: e_15_1 }; }
2651
+ finally {
2652
+ try {
2653
+ if (!_d && !_a && (_b = sseResp_15.return)) yield __await(_b.call(sseResp_15));
2654
+ }
2655
+ finally { if (e_15) throw e_15.error; }
2656
+ }
2657
+ });
2658
+ }
1450
2659
  /**
1451
2660
  * 轻应用-视频理解
1452
2661
  *