@alicloud/aimiaobi20230801 1.32.2 → 1.33.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 (65) hide show
  1. package/dist/client.d.ts +297 -4
  2. package/dist/client.js +2382 -6
  3. package/dist/client.js.map +1 -1
  4. package/dist/models/AddAuditTermsRequest.d.ts +1 -0
  5. package/dist/models/AddAuditTermsRequest.js +5 -0
  6. package/dist/models/AddAuditTermsRequest.js.map +1 -1
  7. package/dist/models/AddAuditTermsShrinkRequest.d.ts +37 -0
  8. package/dist/models/AddAuditTermsShrinkRequest.js +66 -0
  9. package/dist/models/AddAuditTermsShrinkRequest.js.map +1 -0
  10. package/dist/models/DeleteFactAuditUrlRequest.d.ts +29 -0
  11. package/dist/models/DeleteFactAuditUrlRequest.js +60 -0
  12. package/dist/models/DeleteFactAuditUrlRequest.js.map +1 -0
  13. package/dist/models/DeleteFactAuditUrlResponse.d.ts +19 -0
  14. package/dist/models/DeleteFactAuditUrlResponse.js +69 -0
  15. package/dist/models/DeleteFactAuditUrlResponse.js.map +1 -0
  16. package/dist/models/DeleteFactAuditUrlResponseBody.d.ts +46 -0
  17. package/dist/models/DeleteFactAuditUrlResponseBody.js +68 -0
  18. package/dist/models/DeleteFactAuditUrlResponseBody.js.map +1 -0
  19. package/dist/models/EditAuditTermsRequest.d.ts +1 -0
  20. package/dist/models/EditAuditTermsRequest.js +5 -0
  21. package/dist/models/EditAuditTermsRequest.js.map +1 -1
  22. package/dist/models/EditAuditTermsShrinkRequest.d.ts +42 -0
  23. package/dist/models/EditAuditTermsShrinkRequest.js +68 -0
  24. package/dist/models/EditAuditTermsShrinkRequest.js.map +1 -0
  25. package/dist/models/GetFactAuditUrlRequest.d.ts +21 -0
  26. package/dist/models/GetFactAuditUrlRequest.js +58 -0
  27. package/dist/models/GetFactAuditUrlRequest.js.map +1 -0
  28. package/dist/models/GetFactAuditUrlResponse.d.ts +19 -0
  29. package/dist/models/GetFactAuditUrlResponse.js +69 -0
  30. package/dist/models/GetFactAuditUrlResponse.js.map +1 -0
  31. package/dist/models/GetFactAuditUrlResponseBody.d.ts +46 -0
  32. package/dist/models/GetFactAuditUrlResponseBody.js +71 -0
  33. package/dist/models/GetFactAuditUrlResponseBody.js.map +1 -0
  34. package/dist/models/ListAuditTermsResponseBody.d.ts +1 -0
  35. package/dist/models/ListAuditTermsResponseBody.js +5 -0
  36. package/dist/models/ListAuditTermsResponseBody.js.map +1 -1
  37. package/dist/models/SubmitFactAuditUrlRequest.d.ts +29 -0
  38. package/dist/models/SubmitFactAuditUrlRequest.js +60 -0
  39. package/dist/models/SubmitFactAuditUrlRequest.js.map +1 -0
  40. package/dist/models/SubmitFactAuditUrlResponse.d.ts +19 -0
  41. package/dist/models/SubmitFactAuditUrlResponse.js +69 -0
  42. package/dist/models/SubmitFactAuditUrlResponse.js.map +1 -0
  43. package/dist/models/SubmitFactAuditUrlResponseBody.d.ts +46 -0
  44. package/dist/models/SubmitFactAuditUrlResponseBody.js +68 -0
  45. package/dist/models/SubmitFactAuditUrlResponseBody.js.map +1 -0
  46. package/dist/models/model.d.ts +11 -0
  47. package/dist/models/model.js +35 -13
  48. package/dist/models/model.js.map +1 -1
  49. package/package.json +1 -1
  50. package/src/client.ts +2859 -543
  51. package/src/models/AddAuditTermsRequest.ts +6 -0
  52. package/src/models/AddAuditTermsShrinkRequest.ts +58 -0
  53. package/src/models/DeleteFactAuditUrlRequest.ts +44 -0
  54. package/src/models/DeleteFactAuditUrlResponse.ts +40 -0
  55. package/src/models/DeleteFactAuditUrlResponseBody.ts +69 -0
  56. package/src/models/EditAuditTermsRequest.ts +6 -0
  57. package/src/models/EditAuditTermsShrinkRequest.ts +65 -0
  58. package/src/models/GetFactAuditUrlRequest.ts +34 -0
  59. package/src/models/GetFactAuditUrlResponse.ts +40 -0
  60. package/src/models/GetFactAuditUrlResponseBody.ts +72 -0
  61. package/src/models/ListAuditTermsResponseBody.ts +6 -0
  62. package/src/models/SubmitFactAuditUrlRequest.ts +44 -0
  63. package/src/models/SubmitFactAuditUrlResponse.ts +40 -0
  64. package/src/models/SubmitFactAuditUrlResponseBody.ts +69 -0
  65. package/src/models/model.ts +11 -0
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
  };
@@ -64,13 +84,21 @@ class Client extends openapi_core_1.default {
64
84
  /**
65
85
  * 添加审核自定义词库记录
66
86
  *
67
- * @param request - AddAuditTermsRequest
87
+ * @param tmpReq - AddAuditTermsRequest
68
88
  * @param runtime - runtime options for this request RuntimeOptions
69
89
  * @returns AddAuditTermsResponse
70
90
  */
71
- async addAuditTermsWithOptions(request, runtime) {
72
- request.validate();
91
+ async addAuditTermsWithOptions(tmpReq, runtime) {
92
+ tmpReq.validate();
93
+ let request = new $_model.AddAuditTermsShrinkRequest({});
94
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
95
+ if (!$dara.isNull(tmpReq.exceptionWord)) {
96
+ request.exceptionWordShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.exceptionWord, "ExceptionWord", "json");
97
+ }
73
98
  let body = {};
99
+ if (!$dara.isNull(request.exceptionWordShrink)) {
100
+ body["ExceptionWord"] = request.exceptionWordShrink;
101
+ }
74
102
  if (!$dara.isNull(request.keyword)) {
75
103
  body["Keyword"] = request.keyword;
76
104
  }
@@ -1107,6 +1135,48 @@ class Client extends openapi_core_1.default {
1107
1135
  let runtime = new $dara.RuntimeOptions({});
1108
1136
  return await this.deleteDocsWithOptions(request, runtime);
1109
1137
  }
1138
+ /**
1139
+ * 删除指定的用于事实性审核的 URL。
1140
+ *
1141
+ * @param request - DeleteFactAuditUrlRequest
1142
+ * @param runtime - runtime options for this request RuntimeOptions
1143
+ * @returns DeleteFactAuditUrlResponse
1144
+ */
1145
+ async deleteFactAuditUrlWithOptions(request, runtime) {
1146
+ request.validate();
1147
+ let body = {};
1148
+ if (!$dara.isNull(request.url)) {
1149
+ body["Url"] = request.url;
1150
+ }
1151
+ if (!$dara.isNull(request.workspaceId)) {
1152
+ body["WorkspaceId"] = request.workspaceId;
1153
+ }
1154
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
1155
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
1156
+ });
1157
+ let params = new openapi_core_2.$OpenApiUtil.Params({
1158
+ action: "DeleteFactAuditUrl",
1159
+ version: "2023-08-01",
1160
+ protocol: "HTTPS",
1161
+ pathname: "/",
1162
+ method: "POST",
1163
+ authType: "AK",
1164
+ style: "RPC",
1165
+ reqBodyType: "formData",
1166
+ bodyType: "json",
1167
+ });
1168
+ return $dara.cast(await this.callApi(params, req, runtime), new $_model.DeleteFactAuditUrlResponse({}));
1169
+ }
1170
+ /**
1171
+ * 删除指定的用于事实性审核的 URL。
1172
+ *
1173
+ * @param request - DeleteFactAuditUrlRequest
1174
+ * @returns DeleteFactAuditUrlResponse
1175
+ */
1176
+ async deleteFactAuditUrl(request) {
1177
+ let runtime = new $dara.RuntimeOptions({});
1178
+ return await this.deleteFactAuditUrlWithOptions(request, runtime);
1179
+ }
1110
1180
  /**
1111
1181
  * 文档管理-删除。
1112
1182
  *
@@ -1380,13 +1450,21 @@ class Client extends openapi_core_1.default {
1380
1450
  /**
1381
1451
  * 编辑审核自定义词库记录
1382
1452
  *
1383
- * @param request - EditAuditTermsRequest
1453
+ * @param tmpReq - EditAuditTermsRequest
1384
1454
  * @param runtime - runtime options for this request RuntimeOptions
1385
1455
  * @returns EditAuditTermsResponse
1386
1456
  */
1387
- async editAuditTermsWithOptions(request, runtime) {
1388
- request.validate();
1457
+ async editAuditTermsWithOptions(tmpReq, runtime) {
1458
+ tmpReq.validate();
1459
+ let request = new $_model.EditAuditTermsShrinkRequest({});
1460
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
1461
+ if (!$dara.isNull(tmpReq.exceptionWord)) {
1462
+ request.exceptionWordShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.exceptionWord, "ExceptionWord", "json");
1463
+ }
1389
1464
  let body = {};
1465
+ if (!$dara.isNull(request.exceptionWordShrink)) {
1466
+ body["ExceptionWord"] = request.exceptionWordShrink;
1467
+ }
1390
1468
  if (!$dara.isNull(request.id)) {
1391
1469
  body["Id"] = request.id;
1392
1470
  }
@@ -2860,6 +2938,45 @@ class Client extends openapi_core_1.default {
2860
2938
  let runtime = new $dara.RuntimeOptions({});
2861
2939
  return await this.getEnterpriseVocAnalysisTaskWithOptions(request, runtime);
2862
2940
  }
2941
+ /**
2942
+ * 获取当前正用于事实性审核的信源 URL。
2943
+ *
2944
+ * @param request - GetFactAuditUrlRequest
2945
+ * @param runtime - runtime options for this request RuntimeOptions
2946
+ * @returns GetFactAuditUrlResponse
2947
+ */
2948
+ async getFactAuditUrlWithOptions(request, runtime) {
2949
+ request.validate();
2950
+ let body = {};
2951
+ if (!$dara.isNull(request.workspaceId)) {
2952
+ body["WorkspaceId"] = request.workspaceId;
2953
+ }
2954
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
2955
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
2956
+ });
2957
+ let params = new openapi_core_2.$OpenApiUtil.Params({
2958
+ action: "GetFactAuditUrl",
2959
+ version: "2023-08-01",
2960
+ protocol: "HTTPS",
2961
+ pathname: "/",
2962
+ method: "POST",
2963
+ authType: "AK",
2964
+ style: "RPC",
2965
+ reqBodyType: "formData",
2966
+ bodyType: "json",
2967
+ });
2968
+ return $dara.cast(await this.callApi(params, req, runtime), new $_model.GetFactAuditUrlResponse({}));
2969
+ }
2970
+ /**
2971
+ * 获取当前正用于事实性审核的信源 URL。
2972
+ *
2973
+ * @param request - GetFactAuditUrlRequest
2974
+ * @returns GetFactAuditUrlResponse
2975
+ */
2976
+ async getFactAuditUrl(request) {
2977
+ let runtime = new $dara.RuntimeOptions({});
2978
+ return await this.getFactAuditUrlWithOptions(request, runtime);
2979
+ }
2863
2980
  /**
2864
2981
  * 妙读获得文档字数
2865
2982
  *
@@ -5677,6 +5794,64 @@ class Client extends openapi_core_1.default {
5677
5794
  let runtime = new $dara.RuntimeOptions({});
5678
5795
  return await this.queryAuditTaskWithOptions(request, runtime);
5679
5796
  }
5797
+ /**
5798
+ * 内容缩写
5799
+ *
5800
+ * @param request - RunAbbreviationContentRequest
5801
+ * @param runtime - runtime options for this request RuntimeOptions
5802
+ * @returns RunAbbreviationContentResponse
5803
+ */
5804
+ runAbbreviationContentWithSSE(request, runtime) {
5805
+ return __asyncGenerator(this, arguments, function* runAbbreviationContentWithSSE_1() {
5806
+ var _a, e_1, _b, _c;
5807
+ request.validate();
5808
+ let body = {};
5809
+ if (!$dara.isNull(request.content)) {
5810
+ body["Content"] = request.content;
5811
+ }
5812
+ if (!$dara.isNull(request.prompt)) {
5813
+ body["Prompt"] = request.prompt;
5814
+ }
5815
+ if (!$dara.isNull(request.workspaceId)) {
5816
+ body["WorkspaceId"] = request.workspaceId;
5817
+ }
5818
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
5819
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
5820
+ });
5821
+ let params = new openapi_core_2.$OpenApiUtil.Params({
5822
+ action: "RunAbbreviationContent",
5823
+ version: "2023-08-01",
5824
+ protocol: "HTTPS",
5825
+ pathname: "/",
5826
+ method: "POST",
5827
+ authType: "AK",
5828
+ style: "RPC",
5829
+ reqBodyType: "formData",
5830
+ bodyType: "json",
5831
+ });
5832
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
5833
+ try {
5834
+ 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) {
5835
+ _c = sseResp_1_1.value;
5836
+ _d = false;
5837
+ let resp = _c;
5838
+ let data = JSON.parse(resp.event.data);
5839
+ yield yield __await($dara.cast({
5840
+ statusCode: resp.statusCode,
5841
+ headers: resp.headers,
5842
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
5843
+ }, new $_model.RunAbbreviationContentResponse({})));
5844
+ }
5845
+ }
5846
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
5847
+ finally {
5848
+ try {
5849
+ if (!_d && !_a && (_b = sseResp_1.return)) yield __await(_b.call(sseResp_1));
5850
+ }
5851
+ finally { if (e_1) throw e_1.error; }
5852
+ }
5853
+ });
5854
+ }
5680
5855
  /**
5681
5856
  * 内容缩写
5682
5857
  *
@@ -5722,6 +5897,76 @@ class Client extends openapi_core_1.default {
5722
5897
  let runtime = new $dara.RuntimeOptions({});
5723
5898
  return await this.runAbbreviationContentWithOptions(request, runtime);
5724
5899
  }
5900
+ /**
5901
+ * 妙读生成书籍脑图
5902
+ *
5903
+ * @param request - RunBookBrainmapRequest
5904
+ * @param runtime - runtime options for this request RuntimeOptions
5905
+ * @returns RunBookBrainmapResponse
5906
+ */
5907
+ runBookBrainmapWithSSE(request, runtime) {
5908
+ return __asyncGenerator(this, arguments, function* runBookBrainmapWithSSE_1() {
5909
+ var _a, e_2, _b, _c;
5910
+ request.validate();
5911
+ let body = {};
5912
+ if (!$dara.isNull(request.cleanCache)) {
5913
+ body["CleanCache"] = request.cleanCache;
5914
+ }
5915
+ if (!$dara.isNull(request.docId)) {
5916
+ body["DocId"] = request.docId;
5917
+ }
5918
+ if (!$dara.isNull(request.nodeNumber)) {
5919
+ body["NodeNumber"] = request.nodeNumber;
5920
+ }
5921
+ if (!$dara.isNull(request.prompt)) {
5922
+ body["Prompt"] = request.prompt;
5923
+ }
5924
+ if (!$dara.isNull(request.sessionId)) {
5925
+ body["SessionId"] = request.sessionId;
5926
+ }
5927
+ if (!$dara.isNull(request.wordNumber)) {
5928
+ body["WordNumber"] = request.wordNumber;
5929
+ }
5930
+ if (!$dara.isNull(request.workspaceId)) {
5931
+ body["WorkspaceId"] = request.workspaceId;
5932
+ }
5933
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
5934
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
5935
+ });
5936
+ let params = new openapi_core_2.$OpenApiUtil.Params({
5937
+ action: "RunBookBrainmap",
5938
+ version: "2023-08-01",
5939
+ protocol: "HTTPS",
5940
+ pathname: "/",
5941
+ method: "POST",
5942
+ authType: "AK",
5943
+ style: "RPC",
5944
+ reqBodyType: "formData",
5945
+ bodyType: "json",
5946
+ });
5947
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
5948
+ try {
5949
+ 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) {
5950
+ _c = sseResp_2_1.value;
5951
+ _d = false;
5952
+ let resp = _c;
5953
+ let data = JSON.parse(resp.event.data);
5954
+ yield yield __await($dara.cast({
5955
+ statusCode: resp.statusCode,
5956
+ headers: resp.headers,
5957
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
5958
+ }, new $_model.RunBookBrainmapResponse({})));
5959
+ }
5960
+ }
5961
+ catch (e_2_1) { e_2 = { error: e_2_1 }; }
5962
+ finally {
5963
+ try {
5964
+ if (!_d && !_a && (_b = sseResp_2.return)) yield __await(_b.call(sseResp_2));
5965
+ }
5966
+ finally { if (e_2) throw e_2.error; }
5967
+ }
5968
+ });
5969
+ }
5725
5970
  /**
5726
5971
  * 妙读生成书籍脑图
5727
5972
  *
@@ -5779,6 +6024,70 @@ class Client extends openapi_core_1.default {
5779
6024
  let runtime = new $dara.RuntimeOptions({});
5780
6025
  return await this.runBookBrainmapWithOptions(request, runtime);
5781
6026
  }
6027
+ /**
6028
+ * 书籍导读接口
6029
+ *
6030
+ * @param request - RunBookIntroductionRequest
6031
+ * @param runtime - runtime options for this request RuntimeOptions
6032
+ * @returns RunBookIntroductionResponse
6033
+ */
6034
+ runBookIntroductionWithSSE(request, runtime) {
6035
+ return __asyncGenerator(this, arguments, function* runBookIntroductionWithSSE_1() {
6036
+ var _a, e_3, _b, _c;
6037
+ request.validate();
6038
+ let body = {};
6039
+ if (!$dara.isNull(request.docId)) {
6040
+ body["DocId"] = request.docId;
6041
+ }
6042
+ if (!$dara.isNull(request.keyPointPrompt)) {
6043
+ body["KeyPointPrompt"] = request.keyPointPrompt;
6044
+ }
6045
+ if (!$dara.isNull(request.sessionId)) {
6046
+ body["SessionId"] = request.sessionId;
6047
+ }
6048
+ if (!$dara.isNull(request.summaryPrompt)) {
6049
+ body["SummaryPrompt"] = request.summaryPrompt;
6050
+ }
6051
+ if (!$dara.isNull(request.workspaceId)) {
6052
+ body["WorkspaceId"] = request.workspaceId;
6053
+ }
6054
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
6055
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
6056
+ });
6057
+ let params = new openapi_core_2.$OpenApiUtil.Params({
6058
+ action: "RunBookIntroduction",
6059
+ version: "2023-08-01",
6060
+ protocol: "HTTPS",
6061
+ pathname: "/",
6062
+ method: "POST",
6063
+ authType: "AK",
6064
+ style: "RPC",
6065
+ reqBodyType: "formData",
6066
+ bodyType: "json",
6067
+ });
6068
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
6069
+ try {
6070
+ 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) {
6071
+ _c = sseResp_3_1.value;
6072
+ _d = false;
6073
+ let resp = _c;
6074
+ let data = JSON.parse(resp.event.data);
6075
+ yield yield __await($dara.cast({
6076
+ statusCode: resp.statusCode,
6077
+ headers: resp.headers,
6078
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
6079
+ }, new $_model.RunBookIntroductionResponse({})));
6080
+ }
6081
+ }
6082
+ catch (e_3_1) { e_3 = { error: e_3_1 }; }
6083
+ finally {
6084
+ try {
6085
+ if (!_d && !_a && (_b = sseResp_3.return)) yield __await(_b.call(sseResp_3));
6086
+ }
6087
+ finally { if (e_3) throw e_3.error; }
6088
+ }
6089
+ });
6090
+ }
5782
6091
  /**
5783
6092
  * 书籍导读接口
5784
6093
  *
@@ -5830,6 +6139,64 @@ class Client extends openapi_core_1.default {
5830
6139
  let runtime = new $dara.RuntimeOptions({});
5831
6140
  return await this.runBookIntroductionWithOptions(request, runtime);
5832
6141
  }
6142
+ /**
6143
+ * 书籍智能卡片接口
6144
+ *
6145
+ * @param request - RunBookSmartCardRequest
6146
+ * @param runtime - runtime options for this request RuntimeOptions
6147
+ * @returns RunBookSmartCardResponse
6148
+ */
6149
+ runBookSmartCardWithSSE(request, runtime) {
6150
+ return __asyncGenerator(this, arguments, function* runBookSmartCardWithSSE_1() {
6151
+ var _a, e_4, _b, _c;
6152
+ request.validate();
6153
+ let body = {};
6154
+ if (!$dara.isNull(request.docId)) {
6155
+ body["DocId"] = request.docId;
6156
+ }
6157
+ if (!$dara.isNull(request.sessionId)) {
6158
+ body["SessionId"] = request.sessionId;
6159
+ }
6160
+ if (!$dara.isNull(request.workspaceId)) {
6161
+ body["WorkspaceId"] = request.workspaceId;
6162
+ }
6163
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
6164
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
6165
+ });
6166
+ let params = new openapi_core_2.$OpenApiUtil.Params({
6167
+ action: "RunBookSmartCard",
6168
+ version: "2023-08-01",
6169
+ protocol: "HTTPS",
6170
+ pathname: "/",
6171
+ method: "POST",
6172
+ authType: "AK",
6173
+ style: "RPC",
6174
+ reqBodyType: "formData",
6175
+ bodyType: "json",
6176
+ });
6177
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
6178
+ try {
6179
+ 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) {
6180
+ _c = sseResp_4_1.value;
6181
+ _d = false;
6182
+ let resp = _c;
6183
+ let data = JSON.parse(resp.event.data);
6184
+ yield yield __await($dara.cast({
6185
+ statusCode: resp.statusCode,
6186
+ headers: resp.headers,
6187
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
6188
+ }, new $_model.RunBookSmartCardResponse({})));
6189
+ }
6190
+ }
6191
+ catch (e_4_1) { e_4 = { error: e_4_1 }; }
6192
+ finally {
6193
+ try {
6194
+ if (!_d && !_a && (_b = sseResp_4.return)) yield __await(_b.call(sseResp_4));
6195
+ }
6196
+ finally { if (e_4) throw e_4.error; }
6197
+ }
6198
+ });
6199
+ }
5833
6200
  /**
5834
6201
  * 书籍智能卡片接口
5835
6202
  *
@@ -5875,6 +6242,102 @@ class Client extends openapi_core_1.default {
5875
6242
  let runtime = new $dara.RuntimeOptions({});
5876
6243
  return await this.runBookSmartCardWithOptions(request, runtime);
5877
6244
  }
6245
+ /**
6246
+ * 客户之声预测
6247
+ *
6248
+ * @param tmpReq - RunCommentGenerationRequest
6249
+ * @param runtime - runtime options for this request RuntimeOptions
6250
+ * @returns RunCommentGenerationResponse
6251
+ */
6252
+ runCommentGenerationWithSSE(tmpReq, runtime) {
6253
+ return __asyncGenerator(this, arguments, function* runCommentGenerationWithSSE_1() {
6254
+ var _a, e_5, _b, _c;
6255
+ tmpReq.validate();
6256
+ let request = new $_model.RunCommentGenerationShrinkRequest({});
6257
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
6258
+ if (!$dara.isNull(tmpReq.lengthRange)) {
6259
+ request.lengthRangeShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.lengthRange, "LengthRange", "json");
6260
+ }
6261
+ if (!$dara.isNull(tmpReq.sentiment)) {
6262
+ request.sentimentShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.sentiment, "Sentiment", "json");
6263
+ }
6264
+ if (!$dara.isNull(tmpReq.type)) {
6265
+ request.typeShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.type, "Type", "json");
6266
+ }
6267
+ let body = {};
6268
+ if (!$dara.isNull(request.allowEmoji)) {
6269
+ body["AllowEmoji"] = request.allowEmoji;
6270
+ }
6271
+ if (!$dara.isNull(request.extraInfo)) {
6272
+ body["ExtraInfo"] = request.extraInfo;
6273
+ }
6274
+ if (!$dara.isNull(request.length)) {
6275
+ body["Length"] = request.length;
6276
+ }
6277
+ if (!$dara.isNull(request.lengthRangeShrink)) {
6278
+ body["LengthRange"] = request.lengthRangeShrink;
6279
+ }
6280
+ if (!$dara.isNull(request.modelId)) {
6281
+ body["ModelId"] = request.modelId;
6282
+ }
6283
+ if (!$dara.isNull(request.numComments)) {
6284
+ body["NumComments"] = request.numComments;
6285
+ }
6286
+ if (!$dara.isNull(request.sentimentShrink)) {
6287
+ body["Sentiment"] = request.sentimentShrink;
6288
+ }
6289
+ if (!$dara.isNull(request.sessionId)) {
6290
+ body["SessionId"] = request.sessionId;
6291
+ }
6292
+ if (!$dara.isNull(request.sourceMaterial)) {
6293
+ body["SourceMaterial"] = request.sourceMaterial;
6294
+ }
6295
+ if (!$dara.isNull(request.style)) {
6296
+ body["Style"] = request.style;
6297
+ }
6298
+ if (!$dara.isNull(request.typeShrink)) {
6299
+ body["Type"] = request.typeShrink;
6300
+ }
6301
+ if (!$dara.isNull(request.workspaceId)) {
6302
+ body["WorkspaceId"] = request.workspaceId;
6303
+ }
6304
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
6305
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
6306
+ });
6307
+ let params = new openapi_core_2.$OpenApiUtil.Params({
6308
+ action: "RunCommentGeneration",
6309
+ version: "2023-08-01",
6310
+ protocol: "HTTPS",
6311
+ pathname: "/",
6312
+ method: "POST",
6313
+ authType: "AK",
6314
+ style: "RPC",
6315
+ reqBodyType: "formData",
6316
+ bodyType: "json",
6317
+ });
6318
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
6319
+ try {
6320
+ 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) {
6321
+ _c = sseResp_5_1.value;
6322
+ _d = false;
6323
+ let resp = _c;
6324
+ let data = JSON.parse(resp.event.data);
6325
+ yield yield __await($dara.cast({
6326
+ statusCode: resp.statusCode,
6327
+ headers: resp.headers,
6328
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
6329
+ }, new $_model.RunCommentGenerationResponse({})));
6330
+ }
6331
+ }
6332
+ catch (e_5_1) { e_5 = { error: e_5_1 }; }
6333
+ finally {
6334
+ try {
6335
+ if (!_d && !_a && (_b = sseResp_5.return)) yield __await(_b.call(sseResp_5));
6336
+ }
6337
+ finally { if (e_5) throw e_5.error; }
6338
+ }
6339
+ });
6340
+ }
5878
6341
  /**
5879
6342
  * 客户之声预测
5880
6343
  *
@@ -5958,6 +6421,61 @@ class Client extends openapi_core_1.default {
5958
6421
  let runtime = new $dara.RuntimeOptions({});
5959
6422
  return await this.runCommentGenerationWithOptions(request, runtime);
5960
6423
  }
6424
+ /**
6425
+ * 内容续写
6426
+ *
6427
+ * @param request - RunContinueContentRequest
6428
+ * @param runtime - runtime options for this request RuntimeOptions
6429
+ * @returns RunContinueContentResponse
6430
+ */
6431
+ runContinueContentWithSSE(request, runtime) {
6432
+ return __asyncGenerator(this, arguments, function* runContinueContentWithSSE_1() {
6433
+ var _a, e_6, _b, _c;
6434
+ request.validate();
6435
+ let body = {};
6436
+ if (!$dara.isNull(request.content)) {
6437
+ body["Content"] = request.content;
6438
+ }
6439
+ if (!$dara.isNull(request.workspaceId)) {
6440
+ body["WorkspaceId"] = request.workspaceId;
6441
+ }
6442
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
6443
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
6444
+ });
6445
+ let params = new openapi_core_2.$OpenApiUtil.Params({
6446
+ action: "RunContinueContent",
6447
+ version: "2023-08-01",
6448
+ protocol: "HTTPS",
6449
+ pathname: "/",
6450
+ method: "POST",
6451
+ authType: "AK",
6452
+ style: "RPC",
6453
+ reqBodyType: "formData",
6454
+ bodyType: "json",
6455
+ });
6456
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
6457
+ try {
6458
+ 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) {
6459
+ _c = sseResp_6_1.value;
6460
+ _d = false;
6461
+ let resp = _c;
6462
+ let data = JSON.parse(resp.event.data);
6463
+ yield yield __await($dara.cast({
6464
+ statusCode: resp.statusCode,
6465
+ headers: resp.headers,
6466
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
6467
+ }, new $_model.RunContinueContentResponse({})));
6468
+ }
6469
+ }
6470
+ catch (e_6_1) { e_6 = { error: e_6_1 }; }
6471
+ finally {
6472
+ try {
6473
+ if (!_d && !_a && (_b = sseResp_6.return)) yield __await(_b.call(sseResp_6));
6474
+ }
6475
+ finally { if (e_6) throw e_6.error; }
6476
+ }
6477
+ });
6478
+ }
5961
6479
  /**
5962
6480
  * 内容续写
5963
6481
  *
@@ -6000,6 +6518,76 @@ class Client extends openapi_core_1.default {
6000
6518
  let runtime = new $dara.RuntimeOptions({});
6001
6519
  return await this.runContinueContentWithOptions(request, runtime);
6002
6520
  }
6521
+ /**
6522
+ * 自定义热点话题分析
6523
+ *
6524
+ * @param request - RunCustomHotTopicAnalysisRequest
6525
+ * @param runtime - runtime options for this request RuntimeOptions
6526
+ * @returns RunCustomHotTopicAnalysisResponse
6527
+ */
6528
+ runCustomHotTopicAnalysisWithSSE(request, runtime) {
6529
+ return __asyncGenerator(this, arguments, function* runCustomHotTopicAnalysisWithSSE_1() {
6530
+ var _a, e_7, _b, _c;
6531
+ request.validate();
6532
+ let body = {};
6533
+ if (!$dara.isNull(request.askUser)) {
6534
+ body["AskUser"] = request.askUser;
6535
+ }
6536
+ if (!$dara.isNull(request.forceAnalysisExistsTopic)) {
6537
+ body["ForceAnalysisExistsTopic"] = request.forceAnalysisExistsTopic;
6538
+ }
6539
+ if (!$dara.isNull(request.prompt)) {
6540
+ body["Prompt"] = request.prompt;
6541
+ }
6542
+ if (!$dara.isNull(request.sessionId)) {
6543
+ body["SessionId"] = request.sessionId;
6544
+ }
6545
+ if (!$dara.isNull(request.taskId)) {
6546
+ body["TaskId"] = request.taskId;
6547
+ }
6548
+ if (!$dara.isNull(request.userBack)) {
6549
+ body["UserBack"] = request.userBack;
6550
+ }
6551
+ if (!$dara.isNull(request.workspaceId)) {
6552
+ body["WorkspaceId"] = request.workspaceId;
6553
+ }
6554
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
6555
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
6556
+ });
6557
+ let params = new openapi_core_2.$OpenApiUtil.Params({
6558
+ action: "RunCustomHotTopicAnalysis",
6559
+ version: "2023-08-01",
6560
+ protocol: "HTTPS",
6561
+ pathname: "/",
6562
+ method: "POST",
6563
+ authType: "AK",
6564
+ style: "RPC",
6565
+ reqBodyType: "formData",
6566
+ bodyType: "json",
6567
+ });
6568
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
6569
+ try {
6570
+ 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) {
6571
+ _c = sseResp_7_1.value;
6572
+ _d = false;
6573
+ let resp = _c;
6574
+ let data = JSON.parse(resp.event.data);
6575
+ yield yield __await($dara.cast({
6576
+ statusCode: resp.statusCode,
6577
+ headers: resp.headers,
6578
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
6579
+ }, new $_model.RunCustomHotTopicAnalysisResponse({})));
6580
+ }
6581
+ }
6582
+ catch (e_7_1) { e_7 = { error: e_7_1 }; }
6583
+ finally {
6584
+ try {
6585
+ if (!_d && !_a && (_b = sseResp_7.return)) yield __await(_b.call(sseResp_7));
6586
+ }
6587
+ finally { if (e_7) throw e_7.error; }
6588
+ }
6589
+ });
6590
+ }
6003
6591
  /**
6004
6592
  * 自定义热点话题分析
6005
6593
  *
@@ -6057,6 +6645,85 @@ class Client extends openapi_core_1.default {
6057
6645
  let runtime = new $dara.RuntimeOptions({});
6058
6646
  return await this.runCustomHotTopicAnalysisWithOptions(request, runtime);
6059
6647
  }
6648
+ /**
6649
+ * 自定义选题视角分析
6650
+ *
6651
+ * @param request - RunCustomHotTopicViewPointAnalysisRequest
6652
+ * @param runtime - runtime options for this request RuntimeOptions
6653
+ * @returns RunCustomHotTopicViewPointAnalysisResponse
6654
+ */
6655
+ runCustomHotTopicViewPointAnalysisWithSSE(request, runtime) {
6656
+ return __asyncGenerator(this, arguments, function* runCustomHotTopicViewPointAnalysisWithSSE_1() {
6657
+ var _a, e_8, _b, _c;
6658
+ request.validate();
6659
+ let body = {};
6660
+ if (!$dara.isNull(request.askUser)) {
6661
+ body["AskUser"] = request.askUser;
6662
+ }
6663
+ if (!$dara.isNull(request.prompt)) {
6664
+ body["Prompt"] = request.prompt;
6665
+ }
6666
+ if (!$dara.isNull(request.searchQuery)) {
6667
+ body["SearchQuery"] = request.searchQuery;
6668
+ }
6669
+ if (!$dara.isNull(request.skipAskUser)) {
6670
+ body["SkipAskUser"] = request.skipAskUser;
6671
+ }
6672
+ if (!$dara.isNull(request.topic)) {
6673
+ body["Topic"] = request.topic;
6674
+ }
6675
+ if (!$dara.isNull(request.topicId)) {
6676
+ body["TopicId"] = request.topicId;
6677
+ }
6678
+ if (!$dara.isNull(request.topicSource)) {
6679
+ body["TopicSource"] = request.topicSource;
6680
+ }
6681
+ if (!$dara.isNull(request.topicVersion)) {
6682
+ body["TopicVersion"] = request.topicVersion;
6683
+ }
6684
+ if (!$dara.isNull(request.userBack)) {
6685
+ body["UserBack"] = request.userBack;
6686
+ }
6687
+ if (!$dara.isNull(request.workspaceId)) {
6688
+ body["WorkspaceId"] = request.workspaceId;
6689
+ }
6690
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
6691
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
6692
+ });
6693
+ let params = new openapi_core_2.$OpenApiUtil.Params({
6694
+ action: "RunCustomHotTopicViewPointAnalysis",
6695
+ version: "2023-08-01",
6696
+ protocol: "HTTPS",
6697
+ pathname: "/",
6698
+ method: "POST",
6699
+ authType: "AK",
6700
+ style: "RPC",
6701
+ reqBodyType: "formData",
6702
+ bodyType: "json",
6703
+ });
6704
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
6705
+ try {
6706
+ 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) {
6707
+ _c = sseResp_8_1.value;
6708
+ _d = false;
6709
+ let resp = _c;
6710
+ let data = JSON.parse(resp.event.data);
6711
+ yield yield __await($dara.cast({
6712
+ statusCode: resp.statusCode,
6713
+ headers: resp.headers,
6714
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
6715
+ }, new $_model.RunCustomHotTopicViewPointAnalysisResponse({})));
6716
+ }
6717
+ }
6718
+ catch (e_8_1) { e_8 = { error: e_8_1 }; }
6719
+ finally {
6720
+ try {
6721
+ if (!_d && !_a && (_b = sseResp_8.return)) yield __await(_b.call(sseResp_8));
6722
+ }
6723
+ finally { if (e_8) throw e_8.error; }
6724
+ }
6725
+ });
6726
+ }
6060
6727
  /**
6061
6728
  * 自定义选题视角分析
6062
6729
  *
@@ -6123,6 +6790,82 @@ class Client extends openapi_core_1.default {
6123
6790
  let runtime = new $dara.RuntimeOptions({});
6124
6791
  return await this.runCustomHotTopicViewPointAnalysisWithOptions(request, runtime);
6125
6792
  }
6793
+ /**
6794
+ * 妙读脑图生成接口
6795
+ *
6796
+ * @param request - RunDocBrainmapRequest
6797
+ * @param runtime - runtime options for this request RuntimeOptions
6798
+ * @returns RunDocBrainmapResponse
6799
+ */
6800
+ runDocBrainmapWithSSE(request, runtime) {
6801
+ return __asyncGenerator(this, arguments, function* runDocBrainmapWithSSE_1() {
6802
+ var _a, e_9, _b, _c;
6803
+ request.validate();
6804
+ let body = {};
6805
+ if (!$dara.isNull(request.cleanCache)) {
6806
+ body["CleanCache"] = request.cleanCache;
6807
+ }
6808
+ if (!$dara.isNull(request.docId)) {
6809
+ body["DocId"] = request.docId;
6810
+ }
6811
+ if (!$dara.isNull(request.modelName)) {
6812
+ body["ModelName"] = request.modelName;
6813
+ }
6814
+ if (!$dara.isNull(request.nodeNumber)) {
6815
+ body["NodeNumber"] = request.nodeNumber;
6816
+ }
6817
+ if (!$dara.isNull(request.prompt)) {
6818
+ body["Prompt"] = request.prompt;
6819
+ }
6820
+ if (!$dara.isNull(request.sessionId)) {
6821
+ body["SessionId"] = request.sessionId;
6822
+ }
6823
+ if (!$dara.isNull(request.wordNumber)) {
6824
+ body["WordNumber"] = request.wordNumber;
6825
+ }
6826
+ if (!$dara.isNull(request.workspaceId)) {
6827
+ body["WorkspaceId"] = request.workspaceId;
6828
+ }
6829
+ if (!$dara.isNull(request.referenceContent)) {
6830
+ body["referenceContent"] = request.referenceContent;
6831
+ }
6832
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
6833
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
6834
+ });
6835
+ let params = new openapi_core_2.$OpenApiUtil.Params({
6836
+ action: "RunDocBrainmap",
6837
+ version: "2023-08-01",
6838
+ protocol: "HTTPS",
6839
+ pathname: "/",
6840
+ method: "POST",
6841
+ authType: "AK",
6842
+ style: "RPC",
6843
+ reqBodyType: "formData",
6844
+ bodyType: "json",
6845
+ });
6846
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
6847
+ try {
6848
+ 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) {
6849
+ _c = sseResp_9_1.value;
6850
+ _d = false;
6851
+ let resp = _c;
6852
+ let data = JSON.parse(resp.event.data);
6853
+ yield yield __await($dara.cast({
6854
+ statusCode: resp.statusCode,
6855
+ headers: resp.headers,
6856
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
6857
+ }, new $_model.RunDocBrainmapResponse({})));
6858
+ }
6859
+ }
6860
+ catch (e_9_1) { e_9 = { error: e_9_1 }; }
6861
+ finally {
6862
+ try {
6863
+ if (!_d && !_a && (_b = sseResp_9.return)) yield __await(_b.call(sseResp_9));
6864
+ }
6865
+ finally { if (e_9) throw e_9.error; }
6866
+ }
6867
+ });
6868
+ }
6126
6869
  /**
6127
6870
  * 妙读脑图生成接口
6128
6871
  *
@@ -6186,6 +6929,82 @@ class Client extends openapi_core_1.default {
6186
6929
  let runtime = new $dara.RuntimeOptions({});
6187
6930
  return await this.runDocBrainmapWithOptions(request, runtime);
6188
6931
  }
6932
+ /**
6933
+ * 妙读文档导读接口
6934
+ *
6935
+ * @param request - RunDocIntroductionRequest
6936
+ * @param runtime - runtime options for this request RuntimeOptions
6937
+ * @returns RunDocIntroductionResponse
6938
+ */
6939
+ runDocIntroductionWithSSE(request, runtime) {
6940
+ return __asyncGenerator(this, arguments, function* runDocIntroductionWithSSE_1() {
6941
+ var _a, e_10, _b, _c;
6942
+ request.validate();
6943
+ let body = {};
6944
+ if (!$dara.isNull(request.cleanCache)) {
6945
+ body["CleanCache"] = request.cleanCache;
6946
+ }
6947
+ if (!$dara.isNull(request.docId)) {
6948
+ body["DocId"] = request.docId;
6949
+ }
6950
+ if (!$dara.isNull(request.introductionPrompt)) {
6951
+ body["IntroductionPrompt"] = request.introductionPrompt;
6952
+ }
6953
+ if (!$dara.isNull(request.keyPointPrompt)) {
6954
+ body["KeyPointPrompt"] = request.keyPointPrompt;
6955
+ }
6956
+ if (!$dara.isNull(request.modelName)) {
6957
+ body["ModelName"] = request.modelName;
6958
+ }
6959
+ if (!$dara.isNull(request.sessionId)) {
6960
+ body["SessionId"] = request.sessionId;
6961
+ }
6962
+ if (!$dara.isNull(request.summaryPrompt)) {
6963
+ body["SummaryPrompt"] = request.summaryPrompt;
6964
+ }
6965
+ if (!$dara.isNull(request.workspaceId)) {
6966
+ body["WorkspaceId"] = request.workspaceId;
6967
+ }
6968
+ if (!$dara.isNull(request.referenceContent)) {
6969
+ body["referenceContent"] = request.referenceContent;
6970
+ }
6971
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
6972
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
6973
+ });
6974
+ let params = new openapi_core_2.$OpenApiUtil.Params({
6975
+ action: "RunDocIntroduction",
6976
+ version: "2023-08-01",
6977
+ protocol: "HTTPS",
6978
+ pathname: "/",
6979
+ method: "POST",
6980
+ authType: "AK",
6981
+ style: "RPC",
6982
+ reqBodyType: "formData",
6983
+ bodyType: "json",
6984
+ });
6985
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
6986
+ try {
6987
+ 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) {
6988
+ _c = sseResp_10_1.value;
6989
+ _d = false;
6990
+ let resp = _c;
6991
+ let data = JSON.parse(resp.event.data);
6992
+ yield yield __await($dara.cast({
6993
+ statusCode: resp.statusCode,
6994
+ headers: resp.headers,
6995
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
6996
+ }, new $_model.RunDocIntroductionResponse({})));
6997
+ }
6998
+ }
6999
+ catch (e_10_1) { e_10 = { error: e_10_1 }; }
7000
+ finally {
7001
+ try {
7002
+ if (!_d && !_a && (_b = sseResp_10.return)) yield __await(_b.call(sseResp_10));
7003
+ }
7004
+ finally { if (e_10) throw e_10.error; }
7005
+ }
7006
+ });
7007
+ }
6189
7008
  /**
6190
7009
  * 妙读文档导读接口
6191
7010
  *
@@ -6249,6 +7068,93 @@ class Client extends openapi_core_1.default {
6249
7068
  let runtime = new $dara.RuntimeOptions({});
6250
7069
  return await this.runDocIntroductionWithOptions(request, runtime);
6251
7070
  }
7071
+ /**
7072
+ * 妙读问答接口
7073
+ *
7074
+ * @param tmpReq - RunDocQaRequest
7075
+ * @param runtime - runtime options for this request RuntimeOptions
7076
+ * @returns RunDocQaResponse
7077
+ */
7078
+ runDocQaWithSSE(tmpReq, runtime) {
7079
+ return __asyncGenerator(this, arguments, function* runDocQaWithSSE_1() {
7080
+ var _a, e_11, _b, _c;
7081
+ tmpReq.validate();
7082
+ let request = new $_model.RunDocQaShrinkRequest({});
7083
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
7084
+ if (!$dara.isNull(tmpReq.categoryIds)) {
7085
+ request.categoryIdsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.categoryIds, "CategoryIds", "json");
7086
+ }
7087
+ if (!$dara.isNull(tmpReq.conversationContexts)) {
7088
+ request.conversationContextsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.conversationContexts, "ConversationContexts", "json");
7089
+ }
7090
+ if (!$dara.isNull(tmpReq.docIds)) {
7091
+ request.docIdsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.docIds, "DocIds", "json");
7092
+ }
7093
+ let body = {};
7094
+ if (!$dara.isNull(request.categoryIdsShrink)) {
7095
+ body["CategoryIds"] = request.categoryIdsShrink;
7096
+ }
7097
+ if (!$dara.isNull(request.conversationContextsShrink)) {
7098
+ body["ConversationContexts"] = request.conversationContextsShrink;
7099
+ }
7100
+ if (!$dara.isNull(request.docIdsShrink)) {
7101
+ body["DocIds"] = request.docIdsShrink;
7102
+ }
7103
+ if (!$dara.isNull(request.modelName)) {
7104
+ body["ModelName"] = request.modelName;
7105
+ }
7106
+ if (!$dara.isNull(request.query)) {
7107
+ body["Query"] = request.query;
7108
+ }
7109
+ if (!$dara.isNull(request.referenceContent)) {
7110
+ body["ReferenceContent"] = request.referenceContent;
7111
+ }
7112
+ if (!$dara.isNull(request.searchSource)) {
7113
+ body["SearchSource"] = request.searchSource;
7114
+ }
7115
+ if (!$dara.isNull(request.sessionId)) {
7116
+ body["SessionId"] = request.sessionId;
7117
+ }
7118
+ if (!$dara.isNull(request.workspaceId)) {
7119
+ body["WorkspaceId"] = request.workspaceId;
7120
+ }
7121
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
7122
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
7123
+ });
7124
+ let params = new openapi_core_2.$OpenApiUtil.Params({
7125
+ action: "RunDocQa",
7126
+ version: "2023-08-01",
7127
+ protocol: "HTTPS",
7128
+ pathname: "/",
7129
+ method: "POST",
7130
+ authType: "AK",
7131
+ style: "RPC",
7132
+ reqBodyType: "formData",
7133
+ bodyType: "json",
7134
+ });
7135
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
7136
+ try {
7137
+ 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) {
7138
+ _c = sseResp_11_1.value;
7139
+ _d = false;
7140
+ let resp = _c;
7141
+ let data = JSON.parse(resp.event.data);
7142
+ yield yield __await($dara.cast({
7143
+ statusCode: resp.statusCode,
7144
+ headers: resp.headers,
7145
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
7146
+ }, new $_model.RunDocQaResponse({})));
7147
+ }
7148
+ }
7149
+ catch (e_11_1) { e_11 = { error: e_11_1 }; }
7150
+ finally {
7151
+ try {
7152
+ if (!_d && !_a && (_b = sseResp_11.return)) yield __await(_b.call(sseResp_11));
7153
+ }
7154
+ finally { if (e_11) throw e_11.error; }
7155
+ }
7156
+ });
7157
+ }
6252
7158
  /**
6253
7159
  * 妙读问答接口
6254
7160
  *
@@ -6323,6 +7229,70 @@ class Client extends openapi_core_1.default {
6323
7229
  let runtime = new $dara.RuntimeOptions({});
6324
7230
  return await this.runDocQaWithOptions(request, runtime);
6325
7231
  }
7232
+ /**
7233
+ * 文档智能卡片接口
7234
+ *
7235
+ * @param request - RunDocSmartCardRequest
7236
+ * @param runtime - runtime options for this request RuntimeOptions
7237
+ * @returns RunDocSmartCardResponse
7238
+ */
7239
+ runDocSmartCardWithSSE(request, runtime) {
7240
+ return __asyncGenerator(this, arguments, function* runDocSmartCardWithSSE_1() {
7241
+ var _a, e_12, _b, _c;
7242
+ request.validate();
7243
+ let body = {};
7244
+ if (!$dara.isNull(request.docId)) {
7245
+ body["DocId"] = request.docId;
7246
+ }
7247
+ if (!$dara.isNull(request.modelName)) {
7248
+ body["ModelName"] = request.modelName;
7249
+ }
7250
+ if (!$dara.isNull(request.prompt)) {
7251
+ body["Prompt"] = request.prompt;
7252
+ }
7253
+ if (!$dara.isNull(request.sessionId)) {
7254
+ body["SessionId"] = request.sessionId;
7255
+ }
7256
+ if (!$dara.isNull(request.workspaceId)) {
7257
+ body["WorkspaceId"] = request.workspaceId;
7258
+ }
7259
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
7260
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
7261
+ });
7262
+ let params = new openapi_core_2.$OpenApiUtil.Params({
7263
+ action: "RunDocSmartCard",
7264
+ version: "2023-08-01",
7265
+ protocol: "HTTPS",
7266
+ pathname: "/",
7267
+ method: "POST",
7268
+ authType: "AK",
7269
+ style: "RPC",
7270
+ reqBodyType: "formData",
7271
+ bodyType: "json",
7272
+ });
7273
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
7274
+ try {
7275
+ 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) {
7276
+ _c = sseResp_12_1.value;
7277
+ _d = false;
7278
+ let resp = _c;
7279
+ let data = JSON.parse(resp.event.data);
7280
+ yield yield __await($dara.cast({
7281
+ statusCode: resp.statusCode,
7282
+ headers: resp.headers,
7283
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
7284
+ }, new $_model.RunDocSmartCardResponse({})));
7285
+ }
7286
+ }
7287
+ catch (e_12_1) { e_12 = { error: e_12_1 }; }
7288
+ finally {
7289
+ try {
7290
+ if (!_d && !_a && (_b = sseResp_12.return)) yield __await(_b.call(sseResp_12));
7291
+ }
7292
+ finally { if (e_12) throw e_12.error; }
7293
+ }
7294
+ });
7295
+ }
6326
7296
  /**
6327
7297
  * 文档智能卡片接口
6328
7298
  *
@@ -6374,6 +7344,76 @@ class Client extends openapi_core_1.default {
6374
7344
  let runtime = new $dara.RuntimeOptions({});
6375
7345
  return await this.runDocSmartCardWithOptions(request, runtime);
6376
7346
  }
7347
+ /**
7348
+ * 妙读文档总结摘要接口
7349
+ *
7350
+ * @param request - RunDocSummaryRequest
7351
+ * @param runtime - runtime options for this request RuntimeOptions
7352
+ * @returns RunDocSummaryResponse
7353
+ */
7354
+ runDocSummaryWithSSE(request, runtime) {
7355
+ return __asyncGenerator(this, arguments, function* runDocSummaryWithSSE_1() {
7356
+ var _a, e_13, _b, _c;
7357
+ request.validate();
7358
+ let body = {};
7359
+ if (!$dara.isNull(request.cleanCache)) {
7360
+ body["CleanCache"] = request.cleanCache;
7361
+ }
7362
+ if (!$dara.isNull(request.docId)) {
7363
+ body["DocId"] = request.docId;
7364
+ }
7365
+ if (!$dara.isNull(request.modelName)) {
7366
+ body["ModelName"] = request.modelName;
7367
+ }
7368
+ if (!$dara.isNull(request.query)) {
7369
+ body["Query"] = request.query;
7370
+ }
7371
+ if (!$dara.isNull(request.recommendContent)) {
7372
+ body["RecommendContent"] = request.recommendContent;
7373
+ }
7374
+ if (!$dara.isNull(request.sessionId)) {
7375
+ body["SessionId"] = request.sessionId;
7376
+ }
7377
+ if (!$dara.isNull(request.workspaceId)) {
7378
+ body["WorkspaceId"] = request.workspaceId;
7379
+ }
7380
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
7381
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
7382
+ });
7383
+ let params = new openapi_core_2.$OpenApiUtil.Params({
7384
+ action: "RunDocSummary",
7385
+ version: "2023-08-01",
7386
+ protocol: "HTTPS",
7387
+ pathname: "/",
7388
+ method: "POST",
7389
+ authType: "AK",
7390
+ style: "RPC",
7391
+ reqBodyType: "formData",
7392
+ bodyType: "json",
7393
+ });
7394
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
7395
+ try {
7396
+ 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) {
7397
+ _c = sseResp_13_1.value;
7398
+ _d = false;
7399
+ let resp = _c;
7400
+ let data = JSON.parse(resp.event.data);
7401
+ yield yield __await($dara.cast({
7402
+ statusCode: resp.statusCode,
7403
+ headers: resp.headers,
7404
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
7405
+ }, new $_model.RunDocSummaryResponse({})));
7406
+ }
7407
+ }
7408
+ catch (e_13_1) { e_13 = { error: e_13_1 }; }
7409
+ finally {
7410
+ try {
7411
+ if (!_d && !_a && (_b = sseResp_13.return)) yield __await(_b.call(sseResp_13));
7412
+ }
7413
+ finally { if (e_13) throw e_13.error; }
7414
+ }
7415
+ });
7416
+ }
6377
7417
  /**
6378
7418
  * 妙读文档总结摘要接口
6379
7419
  *
@@ -6431,6 +7471,76 @@ class Client extends openapi_core_1.default {
6431
7471
  let runtime = new $dara.RuntimeOptions({});
6432
7472
  return await this.runDocSummaryWithOptions(request, runtime);
6433
7473
  }
7474
+ /**
7475
+ * 妙读文档翻译接口
7476
+ *
7477
+ * @param request - RunDocTranslationRequest
7478
+ * @param runtime - runtime options for this request RuntimeOptions
7479
+ * @returns RunDocTranslationResponse
7480
+ */
7481
+ runDocTranslationWithSSE(request, runtime) {
7482
+ return __asyncGenerator(this, arguments, function* runDocTranslationWithSSE_1() {
7483
+ var _a, e_14, _b, _c;
7484
+ request.validate();
7485
+ let body = {};
7486
+ if (!$dara.isNull(request.cleanCache)) {
7487
+ body["CleanCache"] = request.cleanCache;
7488
+ }
7489
+ if (!$dara.isNull(request.docId)) {
7490
+ body["DocId"] = request.docId;
7491
+ }
7492
+ if (!$dara.isNull(request.modelName)) {
7493
+ body["ModelName"] = request.modelName;
7494
+ }
7495
+ if (!$dara.isNull(request.recommendContent)) {
7496
+ body["RecommendContent"] = request.recommendContent;
7497
+ }
7498
+ if (!$dara.isNull(request.sessionId)) {
7499
+ body["SessionId"] = request.sessionId;
7500
+ }
7501
+ if (!$dara.isNull(request.transType)) {
7502
+ body["TransType"] = request.transType;
7503
+ }
7504
+ if (!$dara.isNull(request.workspaceId)) {
7505
+ body["WorkspaceId"] = request.workspaceId;
7506
+ }
7507
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
7508
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
7509
+ });
7510
+ let params = new openapi_core_2.$OpenApiUtil.Params({
7511
+ action: "RunDocTranslation",
7512
+ version: "2023-08-01",
7513
+ protocol: "HTTPS",
7514
+ pathname: "/",
7515
+ method: "POST",
7516
+ authType: "AK",
7517
+ style: "RPC",
7518
+ reqBodyType: "formData",
7519
+ bodyType: "json",
7520
+ });
7521
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
7522
+ try {
7523
+ 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) {
7524
+ _c = sseResp_14_1.value;
7525
+ _d = false;
7526
+ let resp = _c;
7527
+ let data = JSON.parse(resp.event.data);
7528
+ yield yield __await($dara.cast({
7529
+ statusCode: resp.statusCode,
7530
+ headers: resp.headers,
7531
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
7532
+ }, new $_model.RunDocTranslationResponse({})));
7533
+ }
7534
+ }
7535
+ catch (e_14_1) { e_14 = { error: e_14_1 }; }
7536
+ finally {
7537
+ try {
7538
+ if (!_d && !_a && (_b = sseResp_14.return)) yield __await(_b.call(sseResp_14));
7539
+ }
7540
+ finally { if (e_14) throw e_14.error; }
7541
+ }
7542
+ });
7543
+ }
6434
7544
  /**
6435
7545
  * 妙读文档翻译接口
6436
7546
  *
@@ -6488,6 +7598,82 @@ class Client extends openapi_core_1.default {
6488
7598
  let runtime = new $dara.RuntimeOptions({});
6489
7599
  return await this.runDocTranslationWithOptions(request, runtime);
6490
7600
  }
7601
+ /**
7602
+ * 文档改写
7603
+ *
7604
+ * @param request - RunDocWashingRequest
7605
+ * @param runtime - runtime options for this request RuntimeOptions
7606
+ * @returns RunDocWashingResponse
7607
+ */
7608
+ runDocWashingWithSSE(request, runtime) {
7609
+ return __asyncGenerator(this, arguments, function* runDocWashingWithSSE_1() {
7610
+ var _a, e_15, _b, _c;
7611
+ request.validate();
7612
+ let body = {};
7613
+ if (!$dara.isNull(request.modelId)) {
7614
+ body["ModelId"] = request.modelId;
7615
+ }
7616
+ if (!$dara.isNull(request.prompt)) {
7617
+ body["Prompt"] = request.prompt;
7618
+ }
7619
+ if (!$dara.isNull(request.referenceContent)) {
7620
+ body["ReferenceContent"] = request.referenceContent;
7621
+ }
7622
+ if (!$dara.isNull(request.sessionId)) {
7623
+ body["SessionId"] = request.sessionId;
7624
+ }
7625
+ if (!$dara.isNull(request.topic)) {
7626
+ body["Topic"] = request.topic;
7627
+ }
7628
+ if (!$dara.isNull(request.wordNumber)) {
7629
+ body["WordNumber"] = request.wordNumber;
7630
+ }
7631
+ if (!$dara.isNull(request.workspaceId)) {
7632
+ body["WorkspaceId"] = request.workspaceId;
7633
+ }
7634
+ if (!$dara.isNull(request.writingTypeName)) {
7635
+ body["WritingTypeName"] = request.writingTypeName;
7636
+ }
7637
+ if (!$dara.isNull(request.writingTypeRefDoc)) {
7638
+ body["WritingTypeRefDoc"] = request.writingTypeRefDoc;
7639
+ }
7640
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
7641
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
7642
+ });
7643
+ let params = new openapi_core_2.$OpenApiUtil.Params({
7644
+ action: "RunDocWashing",
7645
+ version: "2023-08-01",
7646
+ protocol: "HTTPS",
7647
+ pathname: "/",
7648
+ method: "POST",
7649
+ authType: "AK",
7650
+ style: "RPC",
7651
+ reqBodyType: "formData",
7652
+ bodyType: "json",
7653
+ });
7654
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
7655
+ try {
7656
+ 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) {
7657
+ _c = sseResp_15_1.value;
7658
+ _d = false;
7659
+ let resp = _c;
7660
+ let data = JSON.parse(resp.event.data);
7661
+ yield yield __await($dara.cast({
7662
+ statusCode: resp.statusCode,
7663
+ headers: resp.headers,
7664
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
7665
+ }, new $_model.RunDocWashingResponse({})));
7666
+ }
7667
+ }
7668
+ catch (e_15_1) { e_15 = { error: e_15_1 }; }
7669
+ finally {
7670
+ try {
7671
+ if (!_d && !_a && (_b = sseResp_15.return)) yield __await(_b.call(sseResp_15));
7672
+ }
7673
+ finally { if (e_15) throw e_15.error; }
7674
+ }
7675
+ });
7676
+ }
6491
7677
  /**
6492
7678
  * 文档改写
6493
7679
  *
@@ -6551,6 +7737,64 @@ class Client extends openapi_core_1.default {
6551
7737
  let runtime = new $dara.RuntimeOptions({});
6552
7738
  return await this.runDocWashingWithOptions(request, runtime);
6553
7739
  }
7740
+ /**
7741
+ * 内容扩写
7742
+ *
7743
+ * @param request - RunExpandContentRequest
7744
+ * @param runtime - runtime options for this request RuntimeOptions
7745
+ * @returns RunExpandContentResponse
7746
+ */
7747
+ runExpandContentWithSSE(request, runtime) {
7748
+ return __asyncGenerator(this, arguments, function* runExpandContentWithSSE_1() {
7749
+ var _a, e_16, _b, _c;
7750
+ request.validate();
7751
+ let body = {};
7752
+ if (!$dara.isNull(request.content)) {
7753
+ body["Content"] = request.content;
7754
+ }
7755
+ if (!$dara.isNull(request.prompt)) {
7756
+ body["Prompt"] = request.prompt;
7757
+ }
7758
+ if (!$dara.isNull(request.workspaceId)) {
7759
+ body["WorkspaceId"] = request.workspaceId;
7760
+ }
7761
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
7762
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
7763
+ });
7764
+ let params = new openapi_core_2.$OpenApiUtil.Params({
7765
+ action: "RunExpandContent",
7766
+ version: "2023-08-01",
7767
+ protocol: "HTTPS",
7768
+ pathname: "/",
7769
+ method: "POST",
7770
+ authType: "AK",
7771
+ style: "RPC",
7772
+ reqBodyType: "formData",
7773
+ bodyType: "json",
7774
+ });
7775
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
7776
+ try {
7777
+ for (var _d = true, sseResp_16 = __asyncValues(sseResp), sseResp_16_1; sseResp_16_1 = yield __await(sseResp_16.next()), _a = sseResp_16_1.done, !_a; _d = true) {
7778
+ _c = sseResp_16_1.value;
7779
+ _d = false;
7780
+ let resp = _c;
7781
+ let data = JSON.parse(resp.event.data);
7782
+ yield yield __await($dara.cast({
7783
+ statusCode: resp.statusCode,
7784
+ headers: resp.headers,
7785
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
7786
+ }, new $_model.RunExpandContentResponse({})));
7787
+ }
7788
+ }
7789
+ catch (e_16_1) { e_16 = { error: e_16_1 }; }
7790
+ finally {
7791
+ try {
7792
+ if (!_d && !_a && (_b = sseResp_16.return)) yield __await(_b.call(sseResp_16));
7793
+ }
7794
+ finally { if (e_16) throw e_16.error; }
7795
+ }
7796
+ });
7797
+ }
6554
7798
  /**
6555
7799
  * 内容扩写
6556
7800
  *
@@ -6596,6 +7840,70 @@ class Client extends openapi_core_1.default {
6596
7840
  let runtime = new $dara.RuntimeOptions({});
6597
7841
  return await this.runExpandContentWithOptions(request, runtime);
6598
7842
  }
7843
+ /**
7844
+ * 妙读猜你想问接口
7845
+ *
7846
+ * @param request - RunGenerateQuestionsRequest
7847
+ * @param runtime - runtime options for this request RuntimeOptions
7848
+ * @returns RunGenerateQuestionsResponse
7849
+ */
7850
+ runGenerateQuestionsWithSSE(request, runtime) {
7851
+ return __asyncGenerator(this, arguments, function* runGenerateQuestionsWithSSE_1() {
7852
+ var _a, e_17, _b, _c;
7853
+ request.validate();
7854
+ let body = {};
7855
+ if (!$dara.isNull(request.docId)) {
7856
+ body["DocId"] = request.docId;
7857
+ }
7858
+ if (!$dara.isNull(request.modelName)) {
7859
+ body["ModelName"] = request.modelName;
7860
+ }
7861
+ if (!$dara.isNull(request.referenceContent)) {
7862
+ body["ReferenceContent"] = request.referenceContent;
7863
+ }
7864
+ if (!$dara.isNull(request.sessionId)) {
7865
+ body["SessionId"] = request.sessionId;
7866
+ }
7867
+ if (!$dara.isNull(request.workspaceId)) {
7868
+ body["WorkspaceId"] = request.workspaceId;
7869
+ }
7870
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
7871
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
7872
+ });
7873
+ let params = new openapi_core_2.$OpenApiUtil.Params({
7874
+ action: "RunGenerateQuestions",
7875
+ version: "2023-08-01",
7876
+ protocol: "HTTPS",
7877
+ pathname: "/",
7878
+ method: "POST",
7879
+ authType: "AK",
7880
+ style: "RPC",
7881
+ reqBodyType: "formData",
7882
+ bodyType: "json",
7883
+ });
7884
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
7885
+ try {
7886
+ for (var _d = true, sseResp_17 = __asyncValues(sseResp), sseResp_17_1; sseResp_17_1 = yield __await(sseResp_17.next()), _a = sseResp_17_1.done, !_a; _d = true) {
7887
+ _c = sseResp_17_1.value;
7888
+ _d = false;
7889
+ let resp = _c;
7890
+ let data = JSON.parse(resp.event.data);
7891
+ yield yield __await($dara.cast({
7892
+ statusCode: resp.statusCode,
7893
+ headers: resp.headers,
7894
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
7895
+ }, new $_model.RunGenerateQuestionsResponse({})));
7896
+ }
7897
+ }
7898
+ catch (e_17_1) { e_17 = { error: e_17_1 }; }
7899
+ finally {
7900
+ try {
7901
+ if (!_d && !_a && (_b = sseResp_17.return)) yield __await(_b.call(sseResp_17));
7902
+ }
7903
+ finally { if (e_17) throw e_17.error; }
7904
+ }
7905
+ });
7906
+ }
6599
7907
  /**
6600
7908
  * 妙读猜你想问接口
6601
7909
  *
@@ -6647,6 +7955,73 @@ class Client extends openapi_core_1.default {
6647
7955
  let runtime = new $dara.RuntimeOptions({});
6648
7956
  return await this.runGenerateQuestionsWithOptions(request, runtime);
6649
7957
  }
7958
+ /**
7959
+ * 妙读文档关键词抽取接口
7960
+ *
7961
+ * @param request - RunHotwordRequest
7962
+ * @param runtime - runtime options for this request RuntimeOptions
7963
+ * @returns RunHotwordResponse
7964
+ */
7965
+ runHotwordWithSSE(request, runtime) {
7966
+ return __asyncGenerator(this, arguments, function* runHotwordWithSSE_1() {
7967
+ var _a, e_18, _b, _c;
7968
+ request.validate();
7969
+ let body = {};
7970
+ if (!$dara.isNull(request.docId)) {
7971
+ body["DocId"] = request.docId;
7972
+ }
7973
+ if (!$dara.isNull(request.modelName)) {
7974
+ body["ModelName"] = request.modelName;
7975
+ }
7976
+ if (!$dara.isNull(request.prompt)) {
7977
+ body["Prompt"] = request.prompt;
7978
+ }
7979
+ if (!$dara.isNull(request.referenceContent)) {
7980
+ body["ReferenceContent"] = request.referenceContent;
7981
+ }
7982
+ if (!$dara.isNull(request.sessionId)) {
7983
+ body["SessionId"] = request.sessionId;
7984
+ }
7985
+ if (!$dara.isNull(request.workspaceId)) {
7986
+ body["WorkspaceId"] = request.workspaceId;
7987
+ }
7988
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
7989
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
7990
+ });
7991
+ let params = new openapi_core_2.$OpenApiUtil.Params({
7992
+ action: "RunHotword",
7993
+ version: "2023-08-01",
7994
+ protocol: "HTTPS",
7995
+ pathname: "/",
7996
+ method: "POST",
7997
+ authType: "AK",
7998
+ style: "RPC",
7999
+ reqBodyType: "formData",
8000
+ bodyType: "json",
8001
+ });
8002
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8003
+ try {
8004
+ for (var _d = true, sseResp_18 = __asyncValues(sseResp), sseResp_18_1; sseResp_18_1 = yield __await(sseResp_18.next()), _a = sseResp_18_1.done, !_a; _d = true) {
8005
+ _c = sseResp_18_1.value;
8006
+ _d = false;
8007
+ let resp = _c;
8008
+ let data = JSON.parse(resp.event.data);
8009
+ yield yield __await($dara.cast({
8010
+ statusCode: resp.statusCode,
8011
+ headers: resp.headers,
8012
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
8013
+ }, new $_model.RunHotwordResponse({})));
8014
+ }
8015
+ }
8016
+ catch (e_18_1) { e_18 = { error: e_18_1 }; }
8017
+ finally {
8018
+ try {
8019
+ if (!_d && !_a && (_b = sseResp_18.return)) yield __await(_b.call(sseResp_18));
8020
+ }
8021
+ finally { if (e_18) throw e_18.error; }
8022
+ }
8023
+ });
8024
+ }
6650
8025
  /**
6651
8026
  * 妙读文档关键词抽取接口
6652
8027
  *
@@ -6701,6 +8076,72 @@ class Client extends openapi_core_1.default {
6701
8076
  let runtime = new $dara.RuntimeOptions({});
6702
8077
  return await this.runHotwordWithOptions(request, runtime);
6703
8078
  }
8079
+ /**
8080
+ * AI妙笔-创作-抽取关键词
8081
+ *
8082
+ * @param tmpReq - RunKeywordsExtractionGenerationRequest
8083
+ * @param runtime - runtime options for this request RuntimeOptions
8084
+ * @returns RunKeywordsExtractionGenerationResponse
8085
+ */
8086
+ runKeywordsExtractionGenerationWithSSE(tmpReq, runtime) {
8087
+ return __asyncGenerator(this, arguments, function* runKeywordsExtractionGenerationWithSSE_1() {
8088
+ var _a, e_19, _b, _c;
8089
+ tmpReq.validate();
8090
+ let request = new $_model.RunKeywordsExtractionGenerationShrinkRequest({});
8091
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
8092
+ if (!$dara.isNull(tmpReq.referenceData)) {
8093
+ request.referenceDataShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.referenceData, "ReferenceData", "json");
8094
+ }
8095
+ let body = {};
8096
+ if (!$dara.isNull(request.prompt)) {
8097
+ body["Prompt"] = request.prompt;
8098
+ }
8099
+ if (!$dara.isNull(request.referenceDataShrink)) {
8100
+ body["ReferenceData"] = request.referenceDataShrink;
8101
+ }
8102
+ if (!$dara.isNull(request.taskId)) {
8103
+ body["TaskId"] = request.taskId;
8104
+ }
8105
+ if (!$dara.isNull(request.workspaceId)) {
8106
+ body["WorkspaceId"] = request.workspaceId;
8107
+ }
8108
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
8109
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
8110
+ });
8111
+ let params = new openapi_core_2.$OpenApiUtil.Params({
8112
+ action: "RunKeywordsExtractionGeneration",
8113
+ version: "2023-08-01",
8114
+ protocol: "HTTPS",
8115
+ pathname: "/",
8116
+ method: "POST",
8117
+ authType: "AK",
8118
+ style: "RPC",
8119
+ reqBodyType: "formData",
8120
+ bodyType: "json",
8121
+ });
8122
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8123
+ try {
8124
+ for (var _d = true, sseResp_19 = __asyncValues(sseResp), sseResp_19_1; sseResp_19_1 = yield __await(sseResp_19.next()), _a = sseResp_19_1.done, !_a; _d = true) {
8125
+ _c = sseResp_19_1.value;
8126
+ _d = false;
8127
+ let resp = _c;
8128
+ let data = JSON.parse(resp.event.data);
8129
+ yield yield __await($dara.cast({
8130
+ statusCode: resp.statusCode,
8131
+ headers: resp.headers,
8132
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
8133
+ }, new $_model.RunKeywordsExtractionGenerationResponse({})));
8134
+ }
8135
+ }
8136
+ catch (e_19_1) { e_19 = { error: e_19_1 }; }
8137
+ finally {
8138
+ try {
8139
+ if (!_d && !_a && (_b = sseResp_19.return)) yield __await(_b.call(sseResp_19));
8140
+ }
8141
+ finally { if (e_19) throw e_19.error; }
8142
+ }
8143
+ });
8144
+ }
6704
8145
  /**
6705
8146
  * AI妙笔-创作-抽取关键词
6706
8147
  *
@@ -6754,6 +8195,78 @@ class Client extends openapi_core_1.default {
6754
8195
  let runtime = new $dara.RuntimeOptions({});
6755
8196
  return await this.runKeywordsExtractionGenerationWithOptions(request, runtime);
6756
8197
  }
8198
+ /**
8199
+ * 文档批量导读
8200
+ *
8201
+ * @param tmpReq - RunMultiDocIntroductionRequest
8202
+ * @param runtime - runtime options for this request RuntimeOptions
8203
+ * @returns RunMultiDocIntroductionResponse
8204
+ */
8205
+ runMultiDocIntroductionWithSSE(tmpReq, runtime) {
8206
+ return __asyncGenerator(this, arguments, function* runMultiDocIntroductionWithSSE_1() {
8207
+ var _a, e_20, _b, _c;
8208
+ tmpReq.validate();
8209
+ let request = new $_model.RunMultiDocIntroductionShrinkRequest({});
8210
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
8211
+ if (!$dara.isNull(tmpReq.docIds)) {
8212
+ request.docIdsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.docIds, "DocIds", "json");
8213
+ }
8214
+ let body = {};
8215
+ if (!$dara.isNull(request.docIdsShrink)) {
8216
+ body["DocIds"] = request.docIdsShrink;
8217
+ }
8218
+ if (!$dara.isNull(request.keyPointPrompt)) {
8219
+ body["KeyPointPrompt"] = request.keyPointPrompt;
8220
+ }
8221
+ if (!$dara.isNull(request.modelName)) {
8222
+ body["ModelName"] = request.modelName;
8223
+ }
8224
+ if (!$dara.isNull(request.sessionId)) {
8225
+ body["SessionId"] = request.sessionId;
8226
+ }
8227
+ if (!$dara.isNull(request.summaryPrompt)) {
8228
+ body["SummaryPrompt"] = request.summaryPrompt;
8229
+ }
8230
+ if (!$dara.isNull(request.workspaceId)) {
8231
+ body["WorkspaceId"] = request.workspaceId;
8232
+ }
8233
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
8234
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
8235
+ });
8236
+ let params = new openapi_core_2.$OpenApiUtil.Params({
8237
+ action: "RunMultiDocIntroduction",
8238
+ version: "2023-08-01",
8239
+ protocol: "HTTPS",
8240
+ pathname: "/",
8241
+ method: "POST",
8242
+ authType: "AK",
8243
+ style: "RPC",
8244
+ reqBodyType: "formData",
8245
+ bodyType: "json",
8246
+ });
8247
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8248
+ try {
8249
+ for (var _d = true, sseResp_20 = __asyncValues(sseResp), sseResp_20_1; sseResp_20_1 = yield __await(sseResp_20.next()), _a = sseResp_20_1.done, !_a; _d = true) {
8250
+ _c = sseResp_20_1.value;
8251
+ _d = false;
8252
+ let resp = _c;
8253
+ let data = JSON.parse(resp.event.data);
8254
+ yield yield __await($dara.cast({
8255
+ statusCode: resp.statusCode,
8256
+ headers: resp.headers,
8257
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
8258
+ }, new $_model.RunMultiDocIntroductionResponse({})));
8259
+ }
8260
+ }
8261
+ catch (e_20_1) { e_20 = { error: e_20_1 }; }
8262
+ finally {
8263
+ try {
8264
+ if (!_d && !_a && (_b = sseResp_20.return)) yield __await(_b.call(sseResp_20));
8265
+ }
8266
+ finally { if (e_20) throw e_20.error; }
8267
+ }
8268
+ });
8269
+ }
6757
8270
  /**
6758
8271
  * 文档批量导读
6759
8272
  *
@@ -6813,6 +8326,84 @@ class Client extends openapi_core_1.default {
6813
8326
  let runtime = new $dara.RuntimeOptions({});
6814
8327
  return await this.runMultiDocIntroductionWithOptions(request, runtime);
6815
8328
  }
8329
+ /**
8330
+ * AI妙搜-智能搜索生成
8331
+ *
8332
+ * @param tmpReq - RunSearchGenerationRequest
8333
+ * @param runtime - runtime options for this request RuntimeOptions
8334
+ * @returns RunSearchGenerationResponse
8335
+ */
8336
+ runSearchGenerationWithSSE(tmpReq, runtime) {
8337
+ return __asyncGenerator(this, arguments, function* runSearchGenerationWithSSE_1() {
8338
+ var _a, e_21, _b, _c;
8339
+ tmpReq.validate();
8340
+ let request = new $_model.RunSearchGenerationShrinkRequest({});
8341
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
8342
+ if (!$dara.isNull(tmpReq.agentContext)) {
8343
+ request.agentContextShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.agentContext, "AgentContext", "json");
8344
+ }
8345
+ if (!$dara.isNull(tmpReq.chatConfig)) {
8346
+ request.chatConfigShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.chatConfig, "ChatConfig", "json");
8347
+ }
8348
+ let body = {};
8349
+ if (!$dara.isNull(request.agentContextShrink)) {
8350
+ body["AgentContext"] = request.agentContextShrink;
8351
+ }
8352
+ if (!$dara.isNull(request.chatConfigShrink)) {
8353
+ body["ChatConfig"] = request.chatConfigShrink;
8354
+ }
8355
+ if (!$dara.isNull(request.modelId)) {
8356
+ body["ModelId"] = request.modelId;
8357
+ }
8358
+ if (!$dara.isNull(request.originalSessionId)) {
8359
+ body["OriginalSessionId"] = request.originalSessionId;
8360
+ }
8361
+ if (!$dara.isNull(request.prompt)) {
8362
+ body["Prompt"] = request.prompt;
8363
+ }
8364
+ if (!$dara.isNull(request.taskId)) {
8365
+ body["TaskId"] = request.taskId;
8366
+ }
8367
+ if (!$dara.isNull(request.workspaceId)) {
8368
+ body["WorkspaceId"] = request.workspaceId;
8369
+ }
8370
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
8371
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
8372
+ });
8373
+ let params = new openapi_core_2.$OpenApiUtil.Params({
8374
+ action: "RunSearchGeneration",
8375
+ version: "2023-08-01",
8376
+ protocol: "HTTPS",
8377
+ pathname: "/",
8378
+ method: "POST",
8379
+ authType: "AK",
8380
+ style: "RPC",
8381
+ reqBodyType: "formData",
8382
+ bodyType: "json",
8383
+ });
8384
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8385
+ try {
8386
+ for (var _d = true, sseResp_21 = __asyncValues(sseResp), sseResp_21_1; sseResp_21_1 = yield __await(sseResp_21.next()), _a = sseResp_21_1.done, !_a; _d = true) {
8387
+ _c = sseResp_21_1.value;
8388
+ _d = false;
8389
+ let resp = _c;
8390
+ let data = JSON.parse(resp.event.data);
8391
+ yield yield __await($dara.cast({
8392
+ statusCode: resp.statusCode,
8393
+ headers: resp.headers,
8394
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
8395
+ }, new $_model.RunSearchGenerationResponse({})));
8396
+ }
8397
+ }
8398
+ catch (e_21_1) { e_21 = { error: e_21_1 }; }
8399
+ finally {
8400
+ try {
8401
+ if (!_d && !_a && (_b = sseResp_21.return)) yield __await(_b.call(sseResp_21));
8402
+ }
8403
+ finally { if (e_21) throw e_21.error; }
8404
+ }
8405
+ });
8406
+ }
6816
8407
  /**
6817
8408
  * AI妙搜-智能搜索生成
6818
8409
  *
@@ -6878,6 +8469,75 @@ class Client extends openapi_core_1.default {
6878
8469
  let runtime = new $dara.RuntimeOptions({});
6879
8470
  return await this.runSearchGenerationWithOptions(request, runtime);
6880
8471
  }
8472
+ /**
8473
+ * 妙搜-文搜文
8474
+ *
8475
+ * @param tmpReq - RunSearchSimilarArticlesRequest
8476
+ * @param runtime - runtime options for this request RuntimeOptions
8477
+ * @returns RunSearchSimilarArticlesResponse
8478
+ */
8479
+ runSearchSimilarArticlesWithSSE(tmpReq, runtime) {
8480
+ return __asyncGenerator(this, arguments, function* runSearchSimilarArticlesWithSSE_1() {
8481
+ var _a, e_22, _b, _c;
8482
+ tmpReq.validate();
8483
+ let request = new $_model.RunSearchSimilarArticlesShrinkRequest({});
8484
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
8485
+ if (!$dara.isNull(tmpReq.chatConfig)) {
8486
+ request.chatConfigShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.chatConfig, "ChatConfig", "json");
8487
+ }
8488
+ let body = {};
8489
+ if (!$dara.isNull(request.chatConfigShrink)) {
8490
+ body["ChatConfig"] = request.chatConfigShrink;
8491
+ }
8492
+ if (!$dara.isNull(request.docType)) {
8493
+ body["DocType"] = request.docType;
8494
+ }
8495
+ if (!$dara.isNull(request.title)) {
8496
+ body["Title"] = request.title;
8497
+ }
8498
+ if (!$dara.isNull(request.url)) {
8499
+ body["Url"] = request.url;
8500
+ }
8501
+ if (!$dara.isNull(request.workspaceId)) {
8502
+ body["WorkspaceId"] = request.workspaceId;
8503
+ }
8504
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
8505
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
8506
+ });
8507
+ let params = new openapi_core_2.$OpenApiUtil.Params({
8508
+ action: "RunSearchSimilarArticles",
8509
+ version: "2023-08-01",
8510
+ protocol: "HTTPS",
8511
+ pathname: "/",
8512
+ method: "POST",
8513
+ authType: "AK",
8514
+ style: "RPC",
8515
+ reqBodyType: "formData",
8516
+ bodyType: "json",
8517
+ });
8518
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8519
+ try {
8520
+ for (var _d = true, sseResp_22 = __asyncValues(sseResp), sseResp_22_1; sseResp_22_1 = yield __await(sseResp_22.next()), _a = sseResp_22_1.done, !_a; _d = true) {
8521
+ _c = sseResp_22_1.value;
8522
+ _d = false;
8523
+ let resp = _c;
8524
+ let data = JSON.parse(resp.event.data);
8525
+ yield yield __await($dara.cast({
8526
+ statusCode: resp.statusCode,
8527
+ headers: resp.headers,
8528
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
8529
+ }, new $_model.RunSearchSimilarArticlesResponse({})));
8530
+ }
8531
+ }
8532
+ catch (e_22_1) { e_22 = { error: e_22_1 }; }
8533
+ finally {
8534
+ try {
8535
+ if (!_d && !_a && (_b = sseResp_22.return)) yield __await(_b.call(sseResp_22));
8536
+ }
8537
+ finally { if (e_22) throw e_22.error; }
8538
+ }
8539
+ });
8540
+ }
6881
8541
  /**
6882
8542
  * 妙搜-文搜文
6883
8543
  *
@@ -6934,6 +8594,84 @@ class Client extends openapi_core_1.default {
6934
8594
  let runtime = new $dara.RuntimeOptions({});
6935
8595
  return await this.runSearchSimilarArticlesWithOptions(request, runtime);
6936
8596
  }
8597
+ /**
8598
+ * 创作-分步骤写作
8599
+ *
8600
+ * @param tmpReq - RunStepByStepWritingRequest
8601
+ * @param runtime - runtime options for this request RuntimeOptions
8602
+ * @returns RunStepByStepWritingResponse
8603
+ */
8604
+ runStepByStepWritingWithSSE(tmpReq, runtime) {
8605
+ return __asyncGenerator(this, arguments, function* runStepByStepWritingWithSSE_1() {
8606
+ var _a, e_23, _b, _c;
8607
+ tmpReq.validate();
8608
+ let request = new $_model.RunStepByStepWritingShrinkRequest({});
8609
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
8610
+ if (!$dara.isNull(tmpReq.referenceData)) {
8611
+ request.referenceDataShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.referenceData, "ReferenceData", "json");
8612
+ }
8613
+ if (!$dara.isNull(tmpReq.writingConfig)) {
8614
+ request.writingConfigShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.writingConfig, "WritingConfig", "json");
8615
+ }
8616
+ let body = {};
8617
+ if (!$dara.isNull(request.originSessionId)) {
8618
+ body["OriginSessionId"] = request.originSessionId;
8619
+ }
8620
+ if (!$dara.isNull(request.prompt)) {
8621
+ body["Prompt"] = request.prompt;
8622
+ }
8623
+ if (!$dara.isNull(request.referenceDataShrink)) {
8624
+ body["ReferenceData"] = request.referenceDataShrink;
8625
+ }
8626
+ if (!$dara.isNull(request.sessionId)) {
8627
+ body["SessionId"] = request.sessionId;
8628
+ }
8629
+ if (!$dara.isNull(request.taskId)) {
8630
+ body["TaskId"] = request.taskId;
8631
+ }
8632
+ if (!$dara.isNull(request.workspaceId)) {
8633
+ body["WorkspaceId"] = request.workspaceId;
8634
+ }
8635
+ if (!$dara.isNull(request.writingConfigShrink)) {
8636
+ body["WritingConfig"] = request.writingConfigShrink;
8637
+ }
8638
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
8639
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
8640
+ });
8641
+ let params = new openapi_core_2.$OpenApiUtil.Params({
8642
+ action: "RunStepByStepWriting",
8643
+ version: "2023-08-01",
8644
+ protocol: "HTTPS",
8645
+ pathname: "/",
8646
+ method: "POST",
8647
+ authType: "AK",
8648
+ style: "RPC",
8649
+ reqBodyType: "formData",
8650
+ bodyType: "json",
8651
+ });
8652
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8653
+ try {
8654
+ for (var _d = true, sseResp_23 = __asyncValues(sseResp), sseResp_23_1; sseResp_23_1 = yield __await(sseResp_23.next()), _a = sseResp_23_1.done, !_a; _d = true) {
8655
+ _c = sseResp_23_1.value;
8656
+ _d = false;
8657
+ let resp = _c;
8658
+ let data = JSON.parse(resp.event.data);
8659
+ yield yield __await($dara.cast({
8660
+ statusCode: resp.statusCode,
8661
+ headers: resp.headers,
8662
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
8663
+ }, new $_model.RunStepByStepWritingResponse({})));
8664
+ }
8665
+ }
8666
+ catch (e_23_1) { e_23 = { error: e_23_1 }; }
8667
+ finally {
8668
+ try {
8669
+ if (!_d && !_a && (_b = sseResp_23.return)) yield __await(_b.call(sseResp_23));
8670
+ }
8671
+ finally { if (e_23) throw e_23.error; }
8672
+ }
8673
+ });
8674
+ }
6937
8675
  /**
6938
8676
  * 创作-分步骤写作
6939
8677
  *
@@ -6999,6 +8737,72 @@ class Client extends openapi_core_1.default {
6999
8737
  let runtime = new $dara.RuntimeOptions({});
7000
8738
  return await this.runStepByStepWritingWithOptions(request, runtime);
7001
8739
  }
8740
+ /**
8741
+ * 内容特点分析
8742
+ *
8743
+ * @param tmpReq - RunStyleFeatureAnalysisRequest
8744
+ * @param runtime - runtime options for this request RuntimeOptions
8745
+ * @returns RunStyleFeatureAnalysisResponse
8746
+ */
8747
+ runStyleFeatureAnalysisWithSSE(tmpReq, runtime) {
8748
+ return __asyncGenerator(this, arguments, function* runStyleFeatureAnalysisWithSSE_1() {
8749
+ var _a, e_24, _b, _c;
8750
+ tmpReq.validate();
8751
+ let request = new $_model.RunStyleFeatureAnalysisShrinkRequest({});
8752
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
8753
+ if (!$dara.isNull(tmpReq.contents)) {
8754
+ request.contentsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.contents, "Contents", "json");
8755
+ }
8756
+ if (!$dara.isNull(tmpReq.materialIds)) {
8757
+ request.materialIdsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.materialIds, "MaterialIds", "json");
8758
+ }
8759
+ let body = {};
8760
+ if (!$dara.isNull(request.contentsShrink)) {
8761
+ body["Contents"] = request.contentsShrink;
8762
+ }
8763
+ if (!$dara.isNull(request.materialIdsShrink)) {
8764
+ body["MaterialIds"] = request.materialIdsShrink;
8765
+ }
8766
+ if (!$dara.isNull(request.workspaceId)) {
8767
+ body["WorkspaceId"] = request.workspaceId;
8768
+ }
8769
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
8770
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
8771
+ });
8772
+ let params = new openapi_core_2.$OpenApiUtil.Params({
8773
+ action: "RunStyleFeatureAnalysis",
8774
+ version: "2023-08-01",
8775
+ protocol: "HTTPS",
8776
+ pathname: "/",
8777
+ method: "POST",
8778
+ authType: "AK",
8779
+ style: "RPC",
8780
+ reqBodyType: "formData",
8781
+ bodyType: "json",
8782
+ });
8783
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8784
+ try {
8785
+ for (var _d = true, sseResp_24 = __asyncValues(sseResp), sseResp_24_1; sseResp_24_1 = yield __await(sseResp_24.next()), _a = sseResp_24_1.done, !_a; _d = true) {
8786
+ _c = sseResp_24_1.value;
8787
+ _d = false;
8788
+ let resp = _c;
8789
+ let data = JSON.parse(resp.event.data);
8790
+ yield yield __await($dara.cast({
8791
+ statusCode: resp.statusCode,
8792
+ headers: resp.headers,
8793
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
8794
+ }, new $_model.RunStyleFeatureAnalysisResponse({})));
8795
+ }
8796
+ }
8797
+ catch (e_24_1) { e_24 = { error: e_24_1 }; }
8798
+ finally {
8799
+ try {
8800
+ if (!_d && !_a && (_b = sseResp_24.return)) yield __await(_b.call(sseResp_24));
8801
+ }
8802
+ finally { if (e_24) throw e_24.error; }
8803
+ }
8804
+ });
8805
+ }
7002
8806
  /**
7003
8807
  * 内容特点分析
7004
8808
  *
@@ -7052,6 +8856,64 @@ class Client extends openapi_core_1.default {
7052
8856
  let runtime = new $dara.RuntimeOptions({});
7053
8857
  return await this.runStyleFeatureAnalysisWithOptions(request, runtime);
7054
8858
  }
8859
+ /**
8860
+ * 内容摘要生成
8861
+ *
8862
+ * @param request - RunSummaryGenerateRequest
8863
+ * @param runtime - runtime options for this request RuntimeOptions
8864
+ * @returns RunSummaryGenerateResponse
8865
+ */
8866
+ runSummaryGenerateWithSSE(request, runtime) {
8867
+ return __asyncGenerator(this, arguments, function* runSummaryGenerateWithSSE_1() {
8868
+ var _a, e_25, _b, _c;
8869
+ request.validate();
8870
+ let body = {};
8871
+ if (!$dara.isNull(request.content)) {
8872
+ body["Content"] = request.content;
8873
+ }
8874
+ if (!$dara.isNull(request.prompt)) {
8875
+ body["Prompt"] = request.prompt;
8876
+ }
8877
+ if (!$dara.isNull(request.workspaceId)) {
8878
+ body["WorkspaceId"] = request.workspaceId;
8879
+ }
8880
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
8881
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
8882
+ });
8883
+ let params = new openapi_core_2.$OpenApiUtil.Params({
8884
+ action: "RunSummaryGenerate",
8885
+ version: "2023-08-01",
8886
+ protocol: "HTTPS",
8887
+ pathname: "/",
8888
+ method: "POST",
8889
+ authType: "AK",
8890
+ style: "RPC",
8891
+ reqBodyType: "formData",
8892
+ bodyType: "json",
8893
+ });
8894
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8895
+ try {
8896
+ for (var _d = true, sseResp_25 = __asyncValues(sseResp), sseResp_25_1; sseResp_25_1 = yield __await(sseResp_25.next()), _a = sseResp_25_1.done, !_a; _d = true) {
8897
+ _c = sseResp_25_1.value;
8898
+ _d = false;
8899
+ let resp = _c;
8900
+ let data = JSON.parse(resp.event.data);
8901
+ yield yield __await($dara.cast({
8902
+ statusCode: resp.statusCode,
8903
+ headers: resp.headers,
8904
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
8905
+ }, new $_model.RunSummaryGenerateResponse({})));
8906
+ }
8907
+ }
8908
+ catch (e_25_1) { e_25 = { error: e_25_1 }; }
8909
+ finally {
8910
+ try {
8911
+ if (!_d && !_a && (_b = sseResp_25.return)) yield __await(_b.call(sseResp_25));
8912
+ }
8913
+ finally { if (e_25) throw e_25.error; }
8914
+ }
8915
+ });
8916
+ }
7055
8917
  /**
7056
8918
  * 内容摘要生成
7057
8919
  *
@@ -7097,6 +8959,64 @@ class Client extends openapi_core_1.default {
7097
8959
  let runtime = new $dara.RuntimeOptions({});
7098
8960
  return await this.runSummaryGenerateWithOptions(request, runtime);
7099
8961
  }
8962
+ /**
8963
+ * 创作-文本润色
8964
+ *
8965
+ * @param request - RunTextPolishingRequest
8966
+ * @param runtime - runtime options for this request RuntimeOptions
8967
+ * @returns RunTextPolishingResponse
8968
+ */
8969
+ runTextPolishingWithSSE(request, runtime) {
8970
+ return __asyncGenerator(this, arguments, function* runTextPolishingWithSSE_1() {
8971
+ var _a, e_26, _b, _c;
8972
+ request.validate();
8973
+ let body = {};
8974
+ if (!$dara.isNull(request.content)) {
8975
+ body["Content"] = request.content;
8976
+ }
8977
+ if (!$dara.isNull(request.prompt)) {
8978
+ body["Prompt"] = request.prompt;
8979
+ }
8980
+ if (!$dara.isNull(request.workspaceId)) {
8981
+ body["WorkspaceId"] = request.workspaceId;
8982
+ }
8983
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
8984
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
8985
+ });
8986
+ let params = new openapi_core_2.$OpenApiUtil.Params({
8987
+ action: "RunTextPolishing",
8988
+ version: "2023-08-01",
8989
+ protocol: "HTTPS",
8990
+ pathname: "/",
8991
+ method: "POST",
8992
+ authType: "AK",
8993
+ style: "RPC",
8994
+ reqBodyType: "formData",
8995
+ bodyType: "json",
8996
+ });
8997
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
8998
+ try {
8999
+ for (var _d = true, sseResp_26 = __asyncValues(sseResp), sseResp_26_1; sseResp_26_1 = yield __await(sseResp_26.next()), _a = sseResp_26_1.done, !_a; _d = true) {
9000
+ _c = sseResp_26_1.value;
9001
+ _d = false;
9002
+ let resp = _c;
9003
+ let data = JSON.parse(resp.event.data);
9004
+ yield yield __await($dara.cast({
9005
+ statusCode: resp.statusCode,
9006
+ headers: resp.headers,
9007
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
9008
+ }, new $_model.RunTextPolishingResponse({})));
9009
+ }
9010
+ }
9011
+ catch (e_26_1) { e_26 = { error: e_26_1 }; }
9012
+ finally {
9013
+ try {
9014
+ if (!_d && !_a && (_b = sseResp_26.return)) yield __await(_b.call(sseResp_26));
9015
+ }
9016
+ finally { if (e_26) throw e_26.error; }
9017
+ }
9018
+ });
9019
+ }
7100
9020
  /**
7101
9021
  * 创作-文本润色
7102
9022
  *
@@ -7142,6 +9062,78 @@ class Client extends openapi_core_1.default {
7142
9062
  let runtime = new $dara.RuntimeOptions({});
7143
9063
  return await this.runTextPolishingWithOptions(request, runtime);
7144
9064
  }
9065
+ /**
9066
+ * 妙笔:标题生成
9067
+ *
9068
+ * @param tmpReq - RunTitleGenerationRequest
9069
+ * @param runtime - runtime options for this request RuntimeOptions
9070
+ * @returns RunTitleGenerationResponse
9071
+ */
9072
+ runTitleGenerationWithSSE(tmpReq, runtime) {
9073
+ return __asyncGenerator(this, arguments, function* runTitleGenerationWithSSE_1() {
9074
+ var _a, e_27, _b, _c;
9075
+ tmpReq.validate();
9076
+ let request = new $_model.RunTitleGenerationShrinkRequest({});
9077
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
9078
+ if (!$dara.isNull(tmpReq.deduplicatedTitles)) {
9079
+ request.deduplicatedTitlesShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.deduplicatedTitles, "DeduplicatedTitles", "json");
9080
+ }
9081
+ if (!$dara.isNull(tmpReq.referenceData)) {
9082
+ request.referenceDataShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.referenceData, "ReferenceData", "json");
9083
+ }
9084
+ let body = {};
9085
+ if (!$dara.isNull(request.deduplicatedTitlesShrink)) {
9086
+ body["DeduplicatedTitles"] = request.deduplicatedTitlesShrink;
9087
+ }
9088
+ if (!$dara.isNull(request.referenceDataShrink)) {
9089
+ body["ReferenceData"] = request.referenceDataShrink;
9090
+ }
9091
+ if (!$dara.isNull(request.taskId)) {
9092
+ body["TaskId"] = request.taskId;
9093
+ }
9094
+ if (!$dara.isNull(request.titleCount)) {
9095
+ body["TitleCount"] = request.titleCount;
9096
+ }
9097
+ if (!$dara.isNull(request.workspaceId)) {
9098
+ body["WorkspaceId"] = request.workspaceId;
9099
+ }
9100
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
9101
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
9102
+ });
9103
+ let params = new openapi_core_2.$OpenApiUtil.Params({
9104
+ action: "RunTitleGeneration",
9105
+ version: "2023-08-01",
9106
+ protocol: "HTTPS",
9107
+ pathname: "/",
9108
+ method: "POST",
9109
+ authType: "AK",
9110
+ style: "RPC",
9111
+ reqBodyType: "formData",
9112
+ bodyType: "json",
9113
+ });
9114
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
9115
+ try {
9116
+ for (var _d = true, sseResp_27 = __asyncValues(sseResp), sseResp_27_1; sseResp_27_1 = yield __await(sseResp_27.next()), _a = sseResp_27_1.done, !_a; _d = true) {
9117
+ _c = sseResp_27_1.value;
9118
+ _d = false;
9119
+ let resp = _c;
9120
+ let data = JSON.parse(resp.event.data);
9121
+ yield yield __await($dara.cast({
9122
+ statusCode: resp.statusCode,
9123
+ headers: resp.headers,
9124
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
9125
+ }, new $_model.RunTitleGenerationResponse({})));
9126
+ }
9127
+ }
9128
+ catch (e_27_1) { e_27 = { error: e_27_1 }; }
9129
+ finally {
9130
+ try {
9131
+ if (!_d && !_a && (_b = sseResp_27.return)) yield __await(_b.call(sseResp_27));
9132
+ }
9133
+ finally { if (e_27) throw e_27.error; }
9134
+ }
9135
+ });
9136
+ }
7145
9137
  /**
7146
9138
  * 妙笔:标题生成
7147
9139
  *
@@ -7201,6 +9193,72 @@ class Client extends openapi_core_1.default {
7201
9193
  let runtime = new $dara.RuntimeOptions({});
7202
9194
  return await this.runTitleGenerationWithOptions(request, runtime);
7203
9195
  }
9196
+ /**
9197
+ * AI妙笔-创作-中英文翻译
9198
+ *
9199
+ * @param tmpReq - RunTranslateGenerationRequest
9200
+ * @param runtime - runtime options for this request RuntimeOptions
9201
+ * @returns RunTranslateGenerationResponse
9202
+ */
9203
+ runTranslateGenerationWithSSE(tmpReq, runtime) {
9204
+ return __asyncGenerator(this, arguments, function* runTranslateGenerationWithSSE_1() {
9205
+ var _a, e_28, _b, _c;
9206
+ tmpReq.validate();
9207
+ let request = new $_model.RunTranslateGenerationShrinkRequest({});
9208
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
9209
+ if (!$dara.isNull(tmpReq.referenceData)) {
9210
+ request.referenceDataShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.referenceData, "ReferenceData", "json");
9211
+ }
9212
+ let body = {};
9213
+ if (!$dara.isNull(request.prompt)) {
9214
+ body["Prompt"] = request.prompt;
9215
+ }
9216
+ if (!$dara.isNull(request.referenceDataShrink)) {
9217
+ body["ReferenceData"] = request.referenceDataShrink;
9218
+ }
9219
+ if (!$dara.isNull(request.taskId)) {
9220
+ body["TaskId"] = request.taskId;
9221
+ }
9222
+ if (!$dara.isNull(request.workspaceId)) {
9223
+ body["WorkspaceId"] = request.workspaceId;
9224
+ }
9225
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
9226
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
9227
+ });
9228
+ let params = new openapi_core_2.$OpenApiUtil.Params({
9229
+ action: "RunTranslateGeneration",
9230
+ version: "2023-08-01",
9231
+ protocol: "HTTPS",
9232
+ pathname: "/",
9233
+ method: "POST",
9234
+ authType: "AK",
9235
+ style: "RPC",
9236
+ reqBodyType: "formData",
9237
+ bodyType: "json",
9238
+ });
9239
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
9240
+ try {
9241
+ for (var _d = true, sseResp_28 = __asyncValues(sseResp), sseResp_28_1; sseResp_28_1 = yield __await(sseResp_28.next()), _a = sseResp_28_1.done, !_a; _d = true) {
9242
+ _c = sseResp_28_1.value;
9243
+ _d = false;
9244
+ let resp = _c;
9245
+ let data = JSON.parse(resp.event.data);
9246
+ yield yield __await($dara.cast({
9247
+ statusCode: resp.statusCode,
9248
+ headers: resp.headers,
9249
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
9250
+ }, new $_model.RunTranslateGenerationResponse({})));
9251
+ }
9252
+ }
9253
+ catch (e_28_1) { e_28 = { error: e_28_1 }; }
9254
+ finally {
9255
+ try {
9256
+ if (!_d && !_a && (_b = sseResp_28.return)) yield __await(_b.call(sseResp_28));
9257
+ }
9258
+ finally { if (e_28) throw e_28.error; }
9259
+ }
9260
+ });
9261
+ }
7204
9262
  /**
7205
9263
  * AI妙笔-创作-中英文翻译
7206
9264
  *
@@ -7254,6 +9312,72 @@ class Client extends openapi_core_1.default {
7254
9312
  let runtime = new $dara.RuntimeOptions({});
7255
9313
  return await this.runTranslateGenerationWithOptions(request, runtime);
7256
9314
  }
9315
+ /**
9316
+ * AI妙笔-创作-文风改写
9317
+ *
9318
+ * @param tmpReq - RunWriteToneGenerationRequest
9319
+ * @param runtime - runtime options for this request RuntimeOptions
9320
+ * @returns RunWriteToneGenerationResponse
9321
+ */
9322
+ runWriteToneGenerationWithSSE(tmpReq, runtime) {
9323
+ return __asyncGenerator(this, arguments, function* runWriteToneGenerationWithSSE_1() {
9324
+ var _a, e_29, _b, _c;
9325
+ tmpReq.validate();
9326
+ let request = new $_model.RunWriteToneGenerationShrinkRequest({});
9327
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
9328
+ if (!$dara.isNull(tmpReq.referenceData)) {
9329
+ request.referenceDataShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.referenceData, "ReferenceData", "json");
9330
+ }
9331
+ let body = {};
9332
+ if (!$dara.isNull(request.prompt)) {
9333
+ body["Prompt"] = request.prompt;
9334
+ }
9335
+ if (!$dara.isNull(request.referenceDataShrink)) {
9336
+ body["ReferenceData"] = request.referenceDataShrink;
9337
+ }
9338
+ if (!$dara.isNull(request.taskId)) {
9339
+ body["TaskId"] = request.taskId;
9340
+ }
9341
+ if (!$dara.isNull(request.workspaceId)) {
9342
+ body["WorkspaceId"] = request.workspaceId;
9343
+ }
9344
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
9345
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
9346
+ });
9347
+ let params = new openapi_core_2.$OpenApiUtil.Params({
9348
+ action: "RunWriteToneGeneration",
9349
+ version: "2023-08-01",
9350
+ protocol: "HTTPS",
9351
+ pathname: "/",
9352
+ method: "POST",
9353
+ authType: "AK",
9354
+ style: "RPC",
9355
+ reqBodyType: "formData",
9356
+ bodyType: "json",
9357
+ });
9358
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
9359
+ try {
9360
+ for (var _d = true, sseResp_29 = __asyncValues(sseResp), sseResp_29_1; sseResp_29_1 = yield __await(sseResp_29.next()), _a = sseResp_29_1.done, !_a; _d = true) {
9361
+ _c = sseResp_29_1.value;
9362
+ _d = false;
9363
+ let resp = _c;
9364
+ let data = JSON.parse(resp.event.data);
9365
+ yield yield __await($dara.cast({
9366
+ statusCode: resp.statusCode,
9367
+ headers: resp.headers,
9368
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
9369
+ }, new $_model.RunWriteToneGenerationResponse({})));
9370
+ }
9371
+ }
9372
+ catch (e_29_1) { e_29 = { error: e_29_1 }; }
9373
+ finally {
9374
+ try {
9375
+ if (!_d && !_a && (_b = sseResp_29.return)) yield __await(_b.call(sseResp_29));
9376
+ }
9377
+ finally { if (e_29) throw e_29.error; }
9378
+ }
9379
+ });
9380
+ }
7257
9381
  /**
7258
9382
  * AI妙笔-创作-文风改写
7259
9383
  *
@@ -7307,6 +9431,84 @@ class Client extends openapi_core_1.default {
7307
9431
  let runtime = new $dara.RuntimeOptions({});
7308
9432
  return await this.runWriteToneGenerationWithOptions(request, runtime);
7309
9433
  }
9434
+ /**
9435
+ * 直接写作
9436
+ *
9437
+ * @param tmpReq - RunWritingRequest
9438
+ * @param runtime - runtime options for this request RuntimeOptions
9439
+ * @returns RunWritingResponse
9440
+ */
9441
+ runWritingWithSSE(tmpReq, runtime) {
9442
+ return __asyncGenerator(this, arguments, function* runWritingWithSSE_1() {
9443
+ var _a, e_30, _b, _c;
9444
+ tmpReq.validate();
9445
+ let request = new $_model.RunWritingShrinkRequest({});
9446
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
9447
+ if (!$dara.isNull(tmpReq.referenceData)) {
9448
+ request.referenceDataShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.referenceData, "ReferenceData", "json");
9449
+ }
9450
+ if (!$dara.isNull(tmpReq.writingConfig)) {
9451
+ request.writingConfigShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.writingConfig, "WritingConfig", "json");
9452
+ }
9453
+ let body = {};
9454
+ if (!$dara.isNull(request.originSessionId)) {
9455
+ body["OriginSessionId"] = request.originSessionId;
9456
+ }
9457
+ if (!$dara.isNull(request.prompt)) {
9458
+ body["Prompt"] = request.prompt;
9459
+ }
9460
+ if (!$dara.isNull(request.referenceDataShrink)) {
9461
+ body["ReferenceData"] = request.referenceDataShrink;
9462
+ }
9463
+ if (!$dara.isNull(request.sessionId)) {
9464
+ body["SessionId"] = request.sessionId;
9465
+ }
9466
+ if (!$dara.isNull(request.taskId)) {
9467
+ body["TaskId"] = request.taskId;
9468
+ }
9469
+ if (!$dara.isNull(request.workspaceId)) {
9470
+ body["WorkspaceId"] = request.workspaceId;
9471
+ }
9472
+ if (!$dara.isNull(request.writingConfigShrink)) {
9473
+ body["WritingConfig"] = request.writingConfigShrink;
9474
+ }
9475
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
9476
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
9477
+ });
9478
+ let params = new openapi_core_2.$OpenApiUtil.Params({
9479
+ action: "RunWriting",
9480
+ version: "2023-08-01",
9481
+ protocol: "HTTPS",
9482
+ pathname: "/",
9483
+ method: "POST",
9484
+ authType: "AK",
9485
+ style: "RPC",
9486
+ reqBodyType: "formData",
9487
+ bodyType: "json",
9488
+ });
9489
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
9490
+ try {
9491
+ for (var _d = true, sseResp_30 = __asyncValues(sseResp), sseResp_30_1; sseResp_30_1 = yield __await(sseResp_30.next()), _a = sseResp_30_1.done, !_a; _d = true) {
9492
+ _c = sseResp_30_1.value;
9493
+ _d = false;
9494
+ let resp = _c;
9495
+ let data = JSON.parse(resp.event.data);
9496
+ yield yield __await($dara.cast({
9497
+ statusCode: resp.statusCode,
9498
+ headers: resp.headers,
9499
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
9500
+ }, new $_model.RunWritingResponse({})));
9501
+ }
9502
+ }
9503
+ catch (e_30_1) { e_30 = { error: e_30_1 }; }
9504
+ finally {
9505
+ try {
9506
+ if (!_d && !_a && (_b = sseResp_30.return)) yield __await(_b.call(sseResp_30));
9507
+ }
9508
+ finally { if (e_30) throw e_30.error; }
9509
+ }
9510
+ });
9511
+ }
7310
9512
  /**
7311
9513
  * 直接写作
7312
9514
  *
@@ -7372,6 +9574,138 @@ class Client extends openapi_core_1.default {
7372
9574
  let runtime = new $dara.RuntimeOptions({});
7373
9575
  return await this.runWritingWithOptions(request, runtime);
7374
9576
  }
9577
+ /**
9578
+ * 直接写作
9579
+ *
9580
+ * @param tmpReq - RunWritingV2Request
9581
+ * @param runtime - runtime options for this request RuntimeOptions
9582
+ * @returns RunWritingV2Response
9583
+ */
9584
+ runWritingV2WithSSE(tmpReq, runtime) {
9585
+ return __asyncGenerator(this, arguments, function* runWritingV2WithSSE_1() {
9586
+ var _a, e_31, _b, _c;
9587
+ tmpReq.validate();
9588
+ let request = new $_model.RunWritingV2ShrinkRequest({});
9589
+ openapi_core_2.OpenApiUtil.convert(tmpReq, request);
9590
+ if (!$dara.isNull(tmpReq.articles)) {
9591
+ request.articlesShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.articles, "Articles", "json");
9592
+ }
9593
+ if (!$dara.isNull(tmpReq.keywords)) {
9594
+ request.keywordsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.keywords, "Keywords", "json");
9595
+ }
9596
+ if (!$dara.isNull(tmpReq.miniDocs)) {
9597
+ request.miniDocsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.miniDocs, "MiniDocs", "json");
9598
+ }
9599
+ if (!$dara.isNull(tmpReq.outlines)) {
9600
+ request.outlinesShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.outlines, "Outlines", "json");
9601
+ }
9602
+ if (!$dara.isNull(tmpReq.searchSources)) {
9603
+ request.searchSourcesShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.searchSources, "SearchSources", "json");
9604
+ }
9605
+ if (!$dara.isNull(tmpReq.summarization)) {
9606
+ request.summarizationShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.summarization, "Summarization", "json");
9607
+ }
9608
+ if (!$dara.isNull(tmpReq.writingParams)) {
9609
+ request.writingParamsShrink = openapi_core_2.OpenApiUtil.arrayToStringWithSpecifiedStyle(tmpReq.writingParams, "WritingParams", "json");
9610
+ }
9611
+ let body = {};
9612
+ if (!$dara.isNull(request.articlesShrink)) {
9613
+ body["Articles"] = request.articlesShrink;
9614
+ }
9615
+ if (!$dara.isNull(request.distributeWriting)) {
9616
+ body["DistributeWriting"] = request.distributeWriting;
9617
+ }
9618
+ if (!$dara.isNull(request.gcNumberSize)) {
9619
+ body["GcNumberSize"] = request.gcNumberSize;
9620
+ }
9621
+ if (!$dara.isNull(request.gcNumberSizeTag)) {
9622
+ body["GcNumberSizeTag"] = request.gcNumberSizeTag;
9623
+ }
9624
+ if (!$dara.isNull(request.keywordsShrink)) {
9625
+ body["Keywords"] = request.keywordsShrink;
9626
+ }
9627
+ if (!$dara.isNull(request.language)) {
9628
+ body["Language"] = request.language;
9629
+ }
9630
+ if (!$dara.isNull(request.miniDocsShrink)) {
9631
+ body["MiniDocs"] = request.miniDocsShrink;
9632
+ }
9633
+ if (!$dara.isNull(request.outlinesShrink)) {
9634
+ body["Outlines"] = request.outlinesShrink;
9635
+ }
9636
+ if (!$dara.isNull(request.prompt)) {
9637
+ body["Prompt"] = request.prompt;
9638
+ }
9639
+ if (!$dara.isNull(request.promptMode)) {
9640
+ body["PromptMode"] = request.promptMode;
9641
+ }
9642
+ if (!$dara.isNull(request.searchSourcesShrink)) {
9643
+ body["SearchSources"] = request.searchSourcesShrink;
9644
+ }
9645
+ if (!$dara.isNull(request.sessionId)) {
9646
+ body["SessionId"] = request.sessionId;
9647
+ }
9648
+ if (!$dara.isNull(request.step)) {
9649
+ body["Step"] = request.step;
9650
+ }
9651
+ if (!$dara.isNull(request.summarizationShrink)) {
9652
+ body["Summarization"] = request.summarizationShrink;
9653
+ }
9654
+ if (!$dara.isNull(request.taskId)) {
9655
+ body["TaskId"] = request.taskId;
9656
+ }
9657
+ if (!$dara.isNull(request.useSearch)) {
9658
+ body["UseSearch"] = request.useSearch;
9659
+ }
9660
+ if (!$dara.isNull(request.workspaceId)) {
9661
+ body["WorkspaceId"] = request.workspaceId;
9662
+ }
9663
+ if (!$dara.isNull(request.writingParamsShrink)) {
9664
+ body["WritingParams"] = request.writingParamsShrink;
9665
+ }
9666
+ if (!$dara.isNull(request.writingScene)) {
9667
+ body["WritingScene"] = request.writingScene;
9668
+ }
9669
+ if (!$dara.isNull(request.writingStyle)) {
9670
+ body["WritingStyle"] = request.writingStyle;
9671
+ }
9672
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
9673
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
9674
+ });
9675
+ let params = new openapi_core_2.$OpenApiUtil.Params({
9676
+ action: "RunWritingV2",
9677
+ version: "2023-08-01",
9678
+ protocol: "HTTPS",
9679
+ pathname: "/",
9680
+ method: "POST",
9681
+ authType: "AK",
9682
+ style: "RPC",
9683
+ reqBodyType: "formData",
9684
+ bodyType: "json",
9685
+ });
9686
+ let sseResp = yield __await(this.callSSEApi(params, req, runtime));
9687
+ try {
9688
+ for (var _d = true, sseResp_31 = __asyncValues(sseResp), sseResp_31_1; sseResp_31_1 = yield __await(sseResp_31.next()), _a = sseResp_31_1.done, !_a; _d = true) {
9689
+ _c = sseResp_31_1.value;
9690
+ _d = false;
9691
+ let resp = _c;
9692
+ let data = JSON.parse(resp.event.data);
9693
+ yield yield __await($dara.cast({
9694
+ statusCode: resp.statusCode,
9695
+ headers: resp.headers,
9696
+ body: Object.assign(Object.assign({}, data), { RequestId: resp.event.id, Message: resp.event.event }),
9697
+ }, new $_model.RunWritingV2Response({})));
9698
+ }
9699
+ }
9700
+ catch (e_31_1) { e_31 = { error: e_31_1 }; }
9701
+ finally {
9702
+ try {
9703
+ if (!_d && !_a && (_b = sseResp_31.return)) yield __await(_b.call(sseResp_31));
9704
+ }
9705
+ finally { if (e_31) throw e_31.error; }
9706
+ }
9707
+ });
9708
+ }
7375
9709
  /**
7376
9710
  * 直接写作
7377
9711
  *
@@ -8363,6 +10697,48 @@ class Client extends openapi_core_1.default {
8363
10697
  let runtime = new $dara.RuntimeOptions({});
8364
10698
  return await this.submitExportTermsTaskWithOptions(request, runtime);
8365
10699
  }
10700
+ /**
10701
+ * 妙笔为您提供了新的事实性审核能力,在联网搜索并判断正误的前提下,还支持用户自定义配置搜索来源 URL。
10702
+ *
10703
+ * @param request - SubmitFactAuditUrlRequest
10704
+ * @param runtime - runtime options for this request RuntimeOptions
10705
+ * @returns SubmitFactAuditUrlResponse
10706
+ */
10707
+ async submitFactAuditUrlWithOptions(request, runtime) {
10708
+ request.validate();
10709
+ let body = {};
10710
+ if (!$dara.isNull(request.url)) {
10711
+ body["Url"] = request.url;
10712
+ }
10713
+ if (!$dara.isNull(request.workspaceId)) {
10714
+ body["WorkspaceId"] = request.workspaceId;
10715
+ }
10716
+ let req = new openapi_core_2.$OpenApiUtil.OpenApiRequest({
10717
+ body: openapi_core_2.OpenApiUtil.parseToMap(body),
10718
+ });
10719
+ let params = new openapi_core_2.$OpenApiUtil.Params({
10720
+ action: "SubmitFactAuditUrl",
10721
+ version: "2023-08-01",
10722
+ protocol: "HTTPS",
10723
+ pathname: "/",
10724
+ method: "POST",
10725
+ authType: "AK",
10726
+ style: "RPC",
10727
+ reqBodyType: "formData",
10728
+ bodyType: "json",
10729
+ });
10730
+ return $dara.cast(await this.callApi(params, req, runtime), new $_model.SubmitFactAuditUrlResponse({}));
10731
+ }
10732
+ /**
10733
+ * 妙笔为您提供了新的事实性审核能力,在联网搜索并判断正误的前提下,还支持用户自定义配置搜索来源 URL。
10734
+ *
10735
+ * @param request - SubmitFactAuditUrlRequest
10736
+ * @returns SubmitFactAuditUrlResponse
10737
+ */
10738
+ async submitFactAuditUrl(request) {
10739
+ let runtime = new $dara.RuntimeOptions({});
10740
+ return await this.submitFactAuditUrlWithOptions(request, runtime);
10741
+ }
8366
10742
  /**
8367
10743
  * 提交导入自定义词库任务
8368
10744
  *