deep-chat-dev 9.0.17 → 9.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/deepChat.js
CHANGED
@@ -553,7 +553,7 @@ function fetchEventSource(r, e) {
|
|
553
553
|
p.accept || (p.accept = EventStreamContentType);
|
554
554
|
var b;
|
555
555
|
function m() {
|
556
|
-
b.abort(), document.hidden ||
|
556
|
+
b.abort(), document.hidden || E();
|
557
557
|
}
|
558
558
|
c || document.addEventListener("visibilitychange", m);
|
559
559
|
var g = DefaultRetryInterval,
|
@@ -566,12 +566,12 @@ function fetchEventSource(r, e) {
|
|
566
566
|
});
|
567
567
|
var S = u !== null && u !== void 0 ? u : window.fetch,
|
568
568
|
_ = s !== null && s !== void 0 ? s : defaultOnOpen;
|
569
|
-
function
|
570
|
-
return
|
569
|
+
function E() {
|
570
|
+
return _E.apply(this, arguments);
|
571
571
|
}
|
572
|
-
function
|
573
|
-
|
574
|
-
var R, w,
|
572
|
+
function _E() {
|
573
|
+
_E = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
|
574
|
+
var R, w, x;
|
575
575
|
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
576
576
|
while (1) switch (_context3.prev = _context3.next) {
|
577
577
|
case 0:
|
@@ -588,10 +588,10 @@ function fetchEventSource(r, e) {
|
|
588
588
|
return _(w);
|
589
589
|
case 7:
|
590
590
|
_context3.next = 9;
|
591
|
-
return getBytes(w.body, getLines(getMessages(function (
|
592
|
-
|
593
|
-
}, function (
|
594
|
-
g =
|
591
|
+
return getBytes(w.body, getLines(getMessages(function (x) {
|
592
|
+
x ? p[LastEventId] = x : delete p[LastEventId];
|
593
|
+
}, function (x) {
|
594
|
+
g = x;
|
595
595
|
}, o)));
|
596
596
|
case 9:
|
597
597
|
a == null || a();
|
@@ -603,10 +603,10 @@ function fetchEventSource(r, e) {
|
|
603
603
|
_context3.prev = 14;
|
604
604
|
_context3.t0 = _context3["catch"](1);
|
605
605
|
if (!b.signal.aborted) try {
|
606
|
-
|
607
|
-
window.clearTimeout(v), v = window.setTimeout(
|
608
|
-
} catch (
|
609
|
-
y(), f(
|
606
|
+
x = (R = l == null ? void 0 : l(_context3.t0)) !== null && R !== void 0 ? R : g;
|
607
|
+
window.clearTimeout(v), v = window.setTimeout(E, x);
|
608
|
+
} catch (x) {
|
609
|
+
y(), f(x);
|
610
610
|
}
|
611
611
|
case 17:
|
612
612
|
case "end":
|
@@ -614,9 +614,9 @@ function fetchEventSource(r, e) {
|
|
614
614
|
}
|
615
615
|
}, _callee3, null, [[1, 14]]);
|
616
616
|
}));
|
617
|
-
return
|
617
|
+
return _E.apply(this, arguments);
|
618
618
|
}
|
619
|
-
|
619
|
+
E();
|
620
620
|
});
|
621
621
|
}
|
622
622
|
function defaultOnOpen(r) {
|
@@ -800,10 +800,10 @@ var Stream = /*#__PURE__*/function () {
|
|
800
800
|
var S;
|
801
801
|
if (JSON.stringify(y.data) !== JSON.stringify("[DONE]")) {
|
802
802
|
var _ = JSON.parse(y.data);
|
803
|
-
(S = e.extractResultData) == null || S.call(e, _).then(function (
|
804
|
-
(
|
805
|
-
})["catch"](function (
|
806
|
-
return RequestUtils.displayError(n,
|
803
|
+
(S = e.extractResultData) == null || S.call(e, _).then(function (E) {
|
804
|
+
(E == null ? void 0 : E.text) === void 0 ? console.error("Response data: ".concat(y.data, " \n ").concat(ErrorMessages.INVALID_STREAM_RESPONSE)) : f && n.updateStreamedMessage(E.text, f);
|
805
|
+
})["catch"](function (E) {
|
806
|
+
return RequestUtils.displayError(n, E);
|
807
807
|
});
|
808
808
|
}
|
809
809
|
},
|
@@ -828,7 +828,7 @@ var Stream = /*#__PURE__*/function () {
|
|
828
828
|
}
|
829
829
|
}, _callee6);
|
830
830
|
}));
|
831
|
-
function request(_x9, _x10
|
831
|
+
function request(_x8, _x9, _x10) {
|
832
832
|
return _request.apply(this, arguments);
|
833
833
|
}
|
834
834
|
return request;
|
@@ -914,7 +914,7 @@ var CustomHandler = /*#__PURE__*/function () {
|
|
914
914
|
}
|
915
915
|
}, _callee7);
|
916
916
|
}));
|
917
|
-
return function o(
|
917
|
+
return function o(_x14) {
|
918
918
|
return _ref2.apply(this, arguments);
|
919
919
|
};
|
920
920
|
}(), a = CustomHandler.generateOptionalSignals();
|
@@ -927,7 +927,7 @@ var CustomHandler = /*#__PURE__*/function () {
|
|
927
927
|
}
|
928
928
|
}, _callee8);
|
929
929
|
}));
|
930
|
-
function request(_x12, _x13
|
930
|
+
function request(_x11, _x12, _x13) {
|
931
931
|
return _request2.apply(this, arguments);
|
932
932
|
}
|
933
933
|
return request;
|
@@ -1007,7 +1007,7 @@ var CustomHandler = /*#__PURE__*/function () {
|
|
1007
1007
|
}
|
1008
1008
|
}, _callee9);
|
1009
1009
|
}));
|
1010
|
-
return function a(
|
1010
|
+
return function a(_x15) {
|
1011
1011
|
return _ref3.apply(this, arguments);
|
1012
1012
|
};
|
1013
1013
|
}(),
|
@@ -1148,7 +1148,7 @@ var HTTPRequest = /*#__PURE__*/function () {
|
|
1148
1148
|
}
|
1149
1149
|
}, _callee10);
|
1150
1150
|
}));
|
1151
|
-
return function (
|
1151
|
+
return function (_x19) {
|
1152
1152
|
return _ref4.apply(this, arguments);
|
1153
1153
|
};
|
1154
1154
|
}())["catch"](function (g) {
|
@@ -1160,7 +1160,7 @@ var HTTPRequest = /*#__PURE__*/function () {
|
|
1160
1160
|
}
|
1161
1161
|
}, _callee11);
|
1162
1162
|
}));
|
1163
|
-
function request(_x17, _x18
|
1163
|
+
function request(_x16, _x17, _x18) {
|
1164
1164
|
return _request3.apply(this, arguments);
|
1165
1165
|
}
|
1166
1166
|
return request;
|
@@ -1209,7 +1209,7 @@ var HTTPRequest = /*#__PURE__*/function () {
|
|
1209
1209
|
}
|
1210
1210
|
}, _callee12);
|
1211
1211
|
}));
|
1212
|
-
return function (
|
1212
|
+
return function (_x20) {
|
1213
1213
|
return _ref5.apply(this, arguments);
|
1214
1214
|
};
|
1215
1215
|
}())["catch"](function (a) {
|
@@ -1268,7 +1268,7 @@ var HTTPRequest = /*#__PURE__*/function () {
|
|
1268
1268
|
}
|
1269
1269
|
}, _callee13);
|
1270
1270
|
}));
|
1271
|
-
function poll(_x22, _x23
|
1271
|
+
function poll(_x21, _x22, _x23) {
|
1272
1272
|
return _poll.apply(this, arguments);
|
1273
1273
|
}
|
1274
1274
|
return poll;
|
@@ -1432,7 +1432,7 @@ var Websocket = /*#__PURE__*/function () {
|
|
1432
1432
|
}
|
1433
1433
|
}, _callee14, null, [[1, 17]]);
|
1434
1434
|
}));
|
1435
|
-
return function (
|
1435
|
+
return function (_x24) {
|
1436
1436
|
return _ref6.apply(this, arguments);
|
1437
1437
|
};
|
1438
1438
|
}(), t.onclose = function () {
|
@@ -1500,7 +1500,7 @@ var Websocket = /*#__PURE__*/function () {
|
|
1500
1500
|
}
|
1501
1501
|
}, _callee15);
|
1502
1502
|
}));
|
1503
|
-
function sendWebsocket(_x26, _x27
|
1503
|
+
function sendWebsocket(_x25, _x26, _x27) {
|
1504
1504
|
return _sendWebsocket.apply(this, arguments);
|
1505
1505
|
}
|
1506
1506
|
return sendWebsocket;
|
@@ -2394,12 +2394,12 @@ function list(r, e, t, n) {
|
|
2394
2394
|
y,
|
2395
2395
|
S,
|
2396
2396
|
_,
|
2397
|
-
|
2397
|
+
E,
|
2398
2398
|
R = !0,
|
2399
2399
|
w,
|
2400
|
-
|
2400
|
+
x,
|
2401
2401
|
H,
|
2402
|
-
|
2402
|
+
U;
|
2403
2403
|
if ((h = skipOrderedListMarker(r, e)) >= 0) g = !0;else if ((h = skipBulletListMarker(r, e)) >= 0) g = !1;else return !1;
|
2404
2404
|
if (r.level >= r.options.maxNesting) return !1;
|
2405
2405
|
if (m = r.src.charCodeAt(h - 1), n) return !0;
|
@@ -2414,17 +2414,17 @@ function list(r, e, t, n) {
|
|
2414
2414
|
level: r.level++
|
2415
2415
|
}), s = e, S = !1, w = r.parser.ruler.getRules("list"); s < t && (v = r.skipSpaces(h), f = r.eMarks[s], v >= f ? p = 1 : p = v - h, p > 4 && (p = 1), p < 1 && (p = 1), o = h - r.bMarks[s] + p, r.tokens.push({
|
2416
2416
|
type: "list_item_open",
|
2417
|
-
lines:
|
2417
|
+
lines: E = [e, 0],
|
2418
2418
|
level: r.level++
|
2419
2419
|
}), l = r.blkIndent, c = r.tight, a = r.tShift[e], u = r.parentType, r.tShift[e] = v - r.bMarks[e], r.blkIndent = o, r.tight = !0, r.parentType = "list", r.parser.tokenize(r, e, t, !0), (!r.tight || S) && (R = !1), S = r.line - e > 1 && r.isEmpty(r.line - 1), r.blkIndent = l, r.tShift[e] = a, r.tight = c, r.parentType = u, r.tokens.push({
|
2420
2420
|
type: "list_item_close",
|
2421
2421
|
level: --r.level
|
2422
|
-
}), s = e = r.line,
|
2423
|
-
for (
|
2424
|
-
|
2422
|
+
}), s = e = r.line, E[1] = s, v = r.bMarks[e], !(s >= t || r.isEmpty(s) || r.tShift[s] < r.blkIndent));) {
|
2423
|
+
for (U = !1, x = 0, H = w.length; x < H; x++) if (w[x](r, s, t, !0)) {
|
2424
|
+
U = !0;
|
2425
2425
|
break;
|
2426
2426
|
}
|
2427
|
-
if (
|
2427
|
+
if (U) break;
|
2428
2428
|
if (g) {
|
2429
2429
|
if (h = skipOrderedListMarker(r, s), h < 0) break;
|
2430
2430
|
} else if (h = skipBulletListMarker(r, s), h < 0) break;
|
@@ -3598,7 +3598,7 @@ var BaseServiceIO = /*#__PURE__*/function () {
|
|
3598
3598
|
}
|
3599
3599
|
}, _callee16, this);
|
3600
3600
|
}));
|
3601
|
-
function callServiceAPI(_x29, _x30
|
3601
|
+
function callServiceAPI(_x28, _x29, _x30) {
|
3602
3602
|
return _callServiceAPI.apply(this, arguments);
|
3603
3603
|
}
|
3604
3604
|
return callServiceAPI;
|
@@ -3623,7 +3623,7 @@ var BaseServiceIO = /*#__PURE__*/function () {
|
|
3623
3623
|
}
|
3624
3624
|
}, _callee17, this);
|
3625
3625
|
}));
|
3626
|
-
function callApiWithFiles(_x32, _x33, _x34
|
3626
|
+
function callApiWithFiles(_x31, _x32, _x33, _x34) {
|
3627
3627
|
return _callApiWithFiles.apply(this, arguments);
|
3628
3628
|
}
|
3629
3629
|
return callApiWithFiles;
|
@@ -3655,7 +3655,7 @@ var BaseServiceIO = /*#__PURE__*/function () {
|
|
3655
3655
|
}
|
3656
3656
|
}, _callee18, this);
|
3657
3657
|
}));
|
3658
|
-
function callAPI(
|
3658
|
+
function callAPI(_x35, _x36) {
|
3659
3659
|
return _callAPI.apply(this, arguments);
|
3660
3660
|
}
|
3661
3661
|
return callAPI;
|
@@ -3681,7 +3681,7 @@ var BaseServiceIO = /*#__PURE__*/function () {
|
|
3681
3681
|
}
|
3682
3682
|
}, _callee19);
|
3683
3683
|
}));
|
3684
|
-
function extractResultData(
|
3684
|
+
function extractResultData(_x37) {
|
3685
3685
|
return _extractResultData.apply(this, arguments);
|
3686
3686
|
}
|
3687
3687
|
return extractResultData;
|
@@ -4032,17 +4032,17 @@ var HuggingFaceUtils = /*#__PURE__*/function () {
|
|
4032
4032
|
return HuggingFaceUtils;
|
4033
4033
|
}();
|
4034
4034
|
var _HuggingFaceIO = /*#__PURE__*/function (_DirectServiceIO) {
|
4035
|
-
_inherits(
|
4036
|
-
var _super3 = _createSuper(
|
4035
|
+
_inherits(F, _DirectServiceIO);
|
4036
|
+
var _super3 = _createSuper(F);
|
4037
4037
|
// prettier-ignore
|
4038
|
-
function
|
4038
|
+
function F(e, t, n, s, o, a) {
|
4039
4039
|
var _this4;
|
4040
|
-
_classCallCheck(this,
|
4041
|
-
_this4 = _super3.call(this, e, HuggingFaceUtils.buildKeyVerificationDetails(), HuggingFaceUtils.buildHeaders, o, a), _this4.insertKeyPlaceholderText = "Hugging Face Token", _this4.getKeyLink = "https://huggingface.co/settings/tokens", _this4.introPanelMarkUp = "\n <div style=\"width: 100%; text-align: center; margin-left: -10px\"><b>Hugging Face</b></div>\n <p>First message may take an extented amount of time to complete as the model needs to be initialized.</p>", _this4.permittedErrorPrefixes = ["Authorization header"], _this4.url = "".concat(
|
4040
|
+
_classCallCheck(this, F);
|
4041
|
+
_this4 = _super3.call(this, e, HuggingFaceUtils.buildKeyVerificationDetails(), HuggingFaceUtils.buildHeaders, o, a), _this4.insertKeyPlaceholderText = "Hugging Face Token", _this4.getKeyLink = "https://huggingface.co/settings/tokens", _this4.introPanelMarkUp = "\n <div style=\"width: 100%; text-align: center; margin-left: -10px\"><b>Hugging Face</b></div>\n <p>First message may take an extented amount of time to complete as the model needs to be initialized.</p>", _this4.permittedErrorPrefixes = ["Authorization header"], _this4.url = "".concat(F.URL_PREFIX).concat(n), _this4.textInputPlaceholderText = t, _typeof(s) == "object" && (s.model && (_this4.url = "".concat(F.URL_PREFIX).concat(s.model)), s.options && (_this4.rawBody.options = s.options), s.parameters && (_this4.rawBody.parameters = s.parameters));
|
4042
4042
|
return _this4;
|
4043
4043
|
}
|
4044
4044
|
// prettier-ignore
|
4045
|
-
_createClass(
|
4045
|
+
_createClass(F, [{
|
4046
4046
|
key: "preprocessBody",
|
4047
4047
|
value: function preprocessBody(e, t, n) {
|
4048
4048
|
var _s$options;
|
@@ -4074,13 +4074,13 @@ var _HuggingFaceIO = /*#__PURE__*/function (_DirectServiceIO) {
|
|
4074
4074
|
}
|
4075
4075
|
}, _callee20, this);
|
4076
4076
|
}));
|
4077
|
-
function callServiceAPI(_x39, _x40
|
4077
|
+
function callServiceAPI(_x38, _x39, _x40) {
|
4078
4078
|
return _callServiceAPI2.apply(this, arguments);
|
4079
4079
|
}
|
4080
4080
|
return callServiceAPI;
|
4081
4081
|
}()
|
4082
4082
|
}]);
|
4083
|
-
return
|
4083
|
+
return F;
|
4084
4084
|
}(DirectServiceIO);
|
4085
4085
|
_HuggingFaceIO.URL_PREFIX = "https://api-inference.huggingface.co/models/";
|
4086
4086
|
var HuggingFaceIO = _HuggingFaceIO;
|
@@ -4126,7 +4126,7 @@ var HuggingFaceFileIO = /*#__PURE__*/function (_HuggingFaceIO2) {
|
|
4126
4126
|
}
|
4127
4127
|
}, _callee21, this);
|
4128
4128
|
}));
|
4129
|
-
function callServiceAPI(_x42, _x43
|
4129
|
+
function callServiceAPI(_x41, _x42, _x43) {
|
4130
4130
|
return _callServiceAPI3.apply(this, arguments);
|
4131
4131
|
}
|
4132
4132
|
return callServiceAPI;
|
@@ -4183,7 +4183,7 @@ var HuggingFaceAudioClassificationIO = /*#__PURE__*/function (_HuggingFaceFileIO
|
|
4183
4183
|
}
|
4184
4184
|
}, _callee22);
|
4185
4185
|
}));
|
4186
|
-
function extractPollResultData(
|
4186
|
+
function extractPollResultData(_x44) {
|
4187
4187
|
return _extractPollResultData.apply(this, arguments);
|
4188
4188
|
}
|
4189
4189
|
return extractPollResultData;
|
@@ -4234,7 +4234,7 @@ var HuggingFaceImageClassificationIO = /*#__PURE__*/function (_HuggingFaceFileIO
|
|
4234
4234
|
}
|
4235
4235
|
}, _callee23);
|
4236
4236
|
}));
|
4237
|
-
function extractPollResultData(
|
4237
|
+
function extractPollResultData(_x45) {
|
4238
4238
|
return _extractPollResultData2.apply(this, arguments);
|
4239
4239
|
}
|
4240
4240
|
return extractPollResultData;
|
@@ -4344,7 +4344,7 @@ var StabilityAIImageToImageUpscaleIO = /*#__PURE__*/function (_StabilityAIIO) {
|
|
4344
4344
|
}
|
4345
4345
|
}, _callee24, this);
|
4346
4346
|
}));
|
4347
|
-
function callServiceAPI(_x47, _x48
|
4347
|
+
function callServiceAPI(_x46, _x47, _x48) {
|
4348
4348
|
return _callServiceAPI4.apply(this, arguments);
|
4349
4349
|
}
|
4350
4350
|
return callServiceAPI;
|
@@ -4376,7 +4376,7 @@ var StabilityAIImageToImageUpscaleIO = /*#__PURE__*/function (_StabilityAIIO) {
|
|
4376
4376
|
}
|
4377
4377
|
}, _callee25);
|
4378
4378
|
}));
|
4379
|
-
function extractResultData(
|
4379
|
+
function extractResultData(_x49) {
|
4380
4380
|
return _extractResultData2.apply(this, arguments);
|
4381
4381
|
}
|
4382
4382
|
return extractResultData;
|
@@ -4453,7 +4453,7 @@ var StabilityAIImageToImageMaskingIO = /*#__PURE__*/function (_StabilityAIIO2) {
|
|
4453
4453
|
}
|
4454
4454
|
}, _callee26, this);
|
4455
4455
|
}));
|
4456
|
-
function callServiceAPI(_x51, _x52
|
4456
|
+
function callServiceAPI(_x50, _x51, _x52) {
|
4457
4457
|
return _callServiceAPI5.apply(this, arguments);
|
4458
4458
|
}
|
4459
4459
|
return callServiceAPI;
|
@@ -4485,7 +4485,7 @@ var StabilityAIImageToImageMaskingIO = /*#__PURE__*/function (_StabilityAIIO2) {
|
|
4485
4485
|
}
|
4486
4486
|
}, _callee27);
|
4487
4487
|
}));
|
4488
|
-
function extractResultData(
|
4488
|
+
function extractResultData(_x53) {
|
4489
4489
|
return _extractResultData3.apply(this, arguments);
|
4490
4490
|
}
|
4491
4491
|
return extractResultData;
|
@@ -4545,7 +4545,7 @@ var HuggingFaceAudioRecognitionIO = /*#__PURE__*/function (_HuggingFaceFileIO3)
|
|
4545
4545
|
}
|
4546
4546
|
}, _callee28);
|
4547
4547
|
}));
|
4548
|
-
function extractPollResultData(
|
4548
|
+
function extractPollResultData(_x54) {
|
4549
4549
|
return _extractPollResultData3.apply(this, arguments);
|
4550
4550
|
}
|
4551
4551
|
return extractPollResultData;
|
@@ -4585,7 +4585,7 @@ var HuggingFaceTextGenerationIO = /*#__PURE__*/function (_HuggingFaceIO3) {
|
|
4585
4585
|
}
|
4586
4586
|
}, _callee29);
|
4587
4587
|
}));
|
4588
|
-
function extractResultData(
|
4588
|
+
function extractResultData(_x55) {
|
4589
4589
|
return _extractResultData4.apply(this, arguments);
|
4590
4590
|
}
|
4591
4591
|
return extractResultData;
|
@@ -4641,7 +4641,7 @@ var HuggingFaceQuestionAnswerIO = /*#__PURE__*/function (_HuggingFaceIO4) {
|
|
4641
4641
|
}
|
4642
4642
|
}, _callee30);
|
4643
4643
|
}));
|
4644
|
-
function extractResultData(
|
4644
|
+
function extractResultData(_x56) {
|
4645
4645
|
return _extractResultData5.apply(this, arguments);
|
4646
4646
|
}
|
4647
4647
|
return extractResultData;
|
@@ -4681,7 +4681,7 @@ var HuggingFaceSummarizationIO = /*#__PURE__*/function (_HuggingFaceIO5) {
|
|
4681
4681
|
}
|
4682
4682
|
}, _callee31);
|
4683
4683
|
}));
|
4684
|
-
function extractResultData(
|
4684
|
+
function extractResultData(_x57) {
|
4685
4685
|
return _extractResultData6.apply(this, arguments);
|
4686
4686
|
}
|
4687
4687
|
return extractResultData;
|
@@ -4761,7 +4761,7 @@ var HuggingFaceConversationIO = /*#__PURE__*/function (_HuggingFaceIO6) {
|
|
4761
4761
|
}
|
4762
4762
|
}, _callee32);
|
4763
4763
|
}));
|
4764
|
-
function extractResultData(
|
4764
|
+
function extractResultData(_x58) {
|
4765
4765
|
return _extractResultData7.apply(this, arguments);
|
4766
4766
|
}
|
4767
4767
|
return extractResultData;
|
@@ -4828,7 +4828,7 @@ var StabilityAIImageToImageIO = /*#__PURE__*/function (_StabilityAIIO3) {
|
|
4828
4828
|
}
|
4829
4829
|
}, _callee33, this);
|
4830
4830
|
}));
|
4831
|
-
function callServiceAPI(_x60, _x61
|
4831
|
+
function callServiceAPI(_x59, _x60, _x61) {
|
4832
4832
|
return _callServiceAPI6.apply(this, arguments);
|
4833
4833
|
}
|
4834
4834
|
return callServiceAPI;
|
@@ -4860,7 +4860,7 @@ var StabilityAIImageToImageIO = /*#__PURE__*/function (_StabilityAIIO3) {
|
|
4860
4860
|
}
|
4861
4861
|
}, _callee34);
|
4862
4862
|
}));
|
4863
|
-
function extractResultData(
|
4863
|
+
function extractResultData(_x62) {
|
4864
4864
|
return _extractResultData8.apply(this, arguments);
|
4865
4865
|
}
|
4866
4866
|
return extractResultData;
|
@@ -4910,7 +4910,7 @@ var HuggingFaceTranslationIO = /*#__PURE__*/function (_HuggingFaceIO7) {
|
|
4910
4910
|
}
|
4911
4911
|
}, _callee35);
|
4912
4912
|
}));
|
4913
|
-
function extractResultData(
|
4913
|
+
function extractResultData(_x63) {
|
4914
4914
|
return _extractResultData9.apply(this, arguments);
|
4915
4915
|
}
|
4916
4916
|
return extractResultData;
|
@@ -4963,7 +4963,7 @@ var StabilityAITextToImageIO = /*#__PURE__*/function (_StabilityAIIO4) {
|
|
4963
4963
|
}
|
4964
4964
|
}, _callee36, this);
|
4965
4965
|
}));
|
4966
|
-
function callServiceAPI(
|
4966
|
+
function callServiceAPI(_x64, _x65) {
|
4967
4967
|
return _callServiceAPI7.apply(this, arguments);
|
4968
4968
|
}
|
4969
4969
|
return callServiceAPI;
|
@@ -4995,7 +4995,7 @@ var StabilityAITextToImageIO = /*#__PURE__*/function (_StabilityAIIO4) {
|
|
4995
4995
|
}
|
4996
4996
|
}, _callee37);
|
4997
4997
|
}));
|
4998
|
-
function extractResultData(
|
4998
|
+
function extractResultData(_x66) {
|
4999
4999
|
return _extractResultData10.apply(this, arguments);
|
5000
5000
|
}
|
5001
5001
|
return extractResultData;
|
@@ -5047,7 +5047,7 @@ var HuggingFaceFillMaskIO = /*#__PURE__*/function (_HuggingFaceIO8) {
|
|
5047
5047
|
}
|
5048
5048
|
}, _callee38);
|
5049
5049
|
}));
|
5050
|
-
function extractResultData(
|
5050
|
+
function extractResultData(_x67) {
|
5051
5051
|
return _extractResultData11.apply(this, arguments);
|
5052
5052
|
}
|
5053
5053
|
return extractResultData;
|
@@ -5141,7 +5141,7 @@ var CohereTextGenerationIO = /*#__PURE__*/function (_CohereIO) {
|
|
5141
5141
|
}
|
5142
5142
|
}, _callee39, this);
|
5143
5143
|
}));
|
5144
|
-
function callServiceAPI(
|
5144
|
+
function callServiceAPI(_x68, _x69) {
|
5145
5145
|
return _callServiceAPI8.apply(this, arguments);
|
5146
5146
|
}
|
5147
5147
|
return callServiceAPI;
|
@@ -5169,7 +5169,7 @@ var CohereTextGenerationIO = /*#__PURE__*/function (_CohereIO) {
|
|
5169
5169
|
}
|
5170
5170
|
}, _callee40);
|
5171
5171
|
}));
|
5172
|
-
function extractResultData(
|
5172
|
+
function extractResultData(_x70) {
|
5173
5173
|
return _extractResultData12.apply(this, arguments);
|
5174
5174
|
}
|
5175
5175
|
return extractResultData;
|
@@ -5218,7 +5218,7 @@ var CohereSummarizationIO = /*#__PURE__*/function (_CohereIO2) {
|
|
5218
5218
|
}
|
5219
5219
|
}, _callee41, this);
|
5220
5220
|
}));
|
5221
|
-
function callServiceAPI(
|
5221
|
+
function callServiceAPI(_x71, _x72) {
|
5222
5222
|
return _callServiceAPI9.apply(this, arguments);
|
5223
5223
|
}
|
5224
5224
|
return callServiceAPI;
|
@@ -5245,7 +5245,7 @@ var CohereSummarizationIO = /*#__PURE__*/function (_CohereIO2) {
|
|
5245
5245
|
}
|
5246
5246
|
}, _callee42);
|
5247
5247
|
}));
|
5248
|
-
function extractResultData(
|
5248
|
+
function extractResultData(_x73) {
|
5249
5249
|
return _extractResultData13.apply(this, arguments);
|
5250
5250
|
}
|
5251
5251
|
return extractResultData;
|
@@ -5421,7 +5421,7 @@ var AzureSummarizationIO = /*#__PURE__*/function (_AzureLanguageIO) {
|
|
5421
5421
|
}
|
5422
5422
|
}, _callee43, this);
|
5423
5423
|
}));
|
5424
|
-
function callServiceAPI(
|
5424
|
+
function callServiceAPI(_x74, _x75) {
|
5425
5425
|
return _callServiceAPI10.apply(this, arguments);
|
5426
5426
|
}
|
5427
5427
|
return callServiceAPI;
|
@@ -5456,7 +5456,7 @@ var AzureSummarizationIO = /*#__PURE__*/function (_AzureLanguageIO) {
|
|
5456
5456
|
}
|
5457
5457
|
}, _callee44, this);
|
5458
5458
|
}));
|
5459
|
-
function extractResultData(
|
5459
|
+
function extractResultData(_x76) {
|
5460
5460
|
return _extractResultData14.apply(this, arguments);
|
5461
5461
|
}
|
5462
5462
|
return extractResultData;
|
@@ -5516,7 +5516,7 @@ var AzureSummarizationIO = /*#__PURE__*/function (_AzureLanguageIO) {
|
|
5516
5516
|
}
|
5517
5517
|
}, _callee45);
|
5518
5518
|
}));
|
5519
|
-
function extractPollResultData(
|
5519
|
+
function extractPollResultData(_x77) {
|
5520
5520
|
return _extractPollResultData4.apply(this, arguments);
|
5521
5521
|
}
|
5522
5522
|
return extractPollResultData;
|
@@ -5634,7 +5634,7 @@ var OpenAICompletionsIO = /*#__PURE__*/function (_DirectServiceIO5) {
|
|
5634
5634
|
}
|
5635
5635
|
}, _callee46, this);
|
5636
5636
|
}));
|
5637
|
-
function callServiceAPI(
|
5637
|
+
function callServiceAPI(_x78, _x79) {
|
5638
5638
|
return _callServiceAPI11.apply(this, arguments);
|
5639
5639
|
}
|
5640
5640
|
return callServiceAPI;
|
@@ -5662,7 +5662,7 @@ var OpenAICompletionsIO = /*#__PURE__*/function (_DirectServiceIO5) {
|
|
5662
5662
|
}
|
5663
5663
|
}, _callee47);
|
5664
5664
|
}));
|
5665
|
-
function extractResultData(
|
5665
|
+
function extractResultData(_x80) {
|
5666
5666
|
return _extractResultData15.apply(this, arguments);
|
5667
5667
|
}
|
5668
5668
|
return extractResultData;
|
@@ -5744,7 +5744,7 @@ var AssemblyAIUtils = /*#__PURE__*/function () {
|
|
5744
5744
|
}
|
5745
5745
|
}, _callee48);
|
5746
5746
|
}));
|
5747
|
-
function poll(
|
5747
|
+
function poll(_x81, _x82) {
|
5748
5748
|
return _poll2.apply(this, arguments);
|
5749
5749
|
}
|
5750
5750
|
return poll;
|
@@ -5816,7 +5816,7 @@ var AssemblyAIAudioIO = /*#__PURE__*/function (_DirectServiceIO6) {
|
|
5816
5816
|
}
|
5817
5817
|
}, _callee49, this);
|
5818
5818
|
}));
|
5819
|
-
function callServiceAPI(_x84, _x85
|
5819
|
+
function callServiceAPI(_x83, _x84, _x85) {
|
5820
5820
|
return _callServiceAPI12.apply(this, arguments);
|
5821
5821
|
}
|
5822
5822
|
return callServiceAPI;
|
@@ -5849,7 +5849,7 @@ var AssemblyAIAudioIO = /*#__PURE__*/function (_DirectServiceIO6) {
|
|
5849
5849
|
}
|
5850
5850
|
}, _callee50, this);
|
5851
5851
|
}));
|
5852
|
-
function extractResultData(
|
5852
|
+
function extractResultData(_x86) {
|
5853
5853
|
return _extractResultData16.apply(this, arguments);
|
5854
5854
|
}
|
5855
5855
|
return extractResultData;
|
@@ -5918,7 +5918,7 @@ var _AzureTextToSpeechIO = /*#__PURE__*/function (_AzureSpeechIO) {
|
|
5918
5918
|
}
|
5919
5919
|
}, _callee51, this);
|
5920
5920
|
}));
|
5921
|
-
function callServiceAPI(
|
5921
|
+
function callServiceAPI(_x87, _x88) {
|
5922
5922
|
return _callServiceAPI13.apply(this, arguments);
|
5923
5923
|
}
|
5924
5924
|
return callServiceAPI;
|
@@ -5947,7 +5947,7 @@ var _AzureTextToSpeechIO = /*#__PURE__*/function (_AzureSpeechIO) {
|
|
5947
5947
|
}
|
5948
5948
|
}, _callee52);
|
5949
5949
|
}));
|
5950
|
-
function extractResultData(
|
5950
|
+
function extractResultData(_x89) {
|
5951
5951
|
return _extractResultData17.apply(this, arguments);
|
5952
5952
|
}
|
5953
5953
|
return extractResultData;
|
@@ -6007,7 +6007,7 @@ var _AzureSpeechToTextIO = /*#__PURE__*/function (_AzureSpeechIO2) {
|
|
6007
6007
|
}
|
6008
6008
|
}, _callee53, this);
|
6009
6009
|
}));
|
6010
|
-
function callServiceAPI(_x91, _x92
|
6010
|
+
function callServiceAPI(_x90, _x91, _x92) {
|
6011
6011
|
return _callServiceAPI14.apply(this, arguments);
|
6012
6012
|
}
|
6013
6013
|
return callServiceAPI;
|
@@ -6034,7 +6034,7 @@ var _AzureSpeechToTextIO = /*#__PURE__*/function (_AzureSpeechIO2) {
|
|
6034
6034
|
}
|
6035
6035
|
}, _callee54);
|
6036
6036
|
}));
|
6037
|
-
function extractResultData(
|
6037
|
+
function extractResultData(_x93) {
|
6038
6038
|
return _extractResultData18.apply(this, arguments);
|
6039
6039
|
}
|
6040
6040
|
return extractResultData;
|
@@ -6096,7 +6096,7 @@ var AzureTranslationIO = /*#__PURE__*/function (_DirectServiceIO8) {
|
|
6096
6096
|
}
|
6097
6097
|
}, _callee55, this);
|
6098
6098
|
}));
|
6099
|
-
function callServiceAPI(
|
6099
|
+
function callServiceAPI(_x94, _x95) {
|
6100
6100
|
return _callServiceAPI15.apply(this, arguments);
|
6101
6101
|
}
|
6102
6102
|
return callServiceAPI;
|
@@ -6124,7 +6124,7 @@ var AzureTranslationIO = /*#__PURE__*/function (_DirectServiceIO8) {
|
|
6124
6124
|
}
|
6125
6125
|
}, _callee56);
|
6126
6126
|
}));
|
6127
|
-
function extractResultData(
|
6127
|
+
function extractResultData(_x96) {
|
6128
6128
|
return _extractResultData19.apply(this, arguments);
|
6129
6129
|
}
|
6130
6130
|
return extractResultData;
|
@@ -6225,7 +6225,7 @@ var _OpenAIImagesIO = /*#__PURE__*/function (_DirectServiceIO9) {
|
|
6225
6225
|
}
|
6226
6226
|
}, _callee57, this);
|
6227
6227
|
}));
|
6228
|
-
function callServiceAPI(_x98, _x99
|
6228
|
+
function callServiceAPI(_x97, _x98, _x99) {
|
6229
6229
|
return _callServiceAPI16.apply(this, arguments);
|
6230
6230
|
}
|
6231
6231
|
return callServiceAPI;
|
@@ -6260,7 +6260,7 @@ var _OpenAIImagesIO = /*#__PURE__*/function (_DirectServiceIO9) {
|
|
6260
6260
|
}
|
6261
6261
|
}, _callee58);
|
6262
6262
|
}));
|
6263
|
-
function extractResultData(
|
6263
|
+
function extractResultData(_x100) {
|
6264
6264
|
return _extractResultData20.apply(this, arguments);
|
6265
6265
|
}
|
6266
6266
|
return extractResultData;
|
@@ -6358,7 +6358,7 @@ var _OpenAIAudioIO = /*#__PURE__*/function (_DirectServiceIO10) {
|
|
6358
6358
|
}
|
6359
6359
|
}, _callee59, this);
|
6360
6360
|
}));
|
6361
|
-
function callServiceAPI(_x102, _x103
|
6361
|
+
function callServiceAPI(_x101, _x102, _x103) {
|
6362
6362
|
return _callServiceAPI17.apply(this, arguments);
|
6363
6363
|
}
|
6364
6364
|
return callServiceAPI;
|
@@ -6385,7 +6385,7 @@ var _OpenAIAudioIO = /*#__PURE__*/function (_DirectServiceIO10) {
|
|
6385
6385
|
}
|
6386
6386
|
}, _callee60);
|
6387
6387
|
}));
|
6388
|
-
function extractResultData(
|
6388
|
+
function extractResultData(_x104) {
|
6389
6389
|
return _extractResultData21.apply(this, arguments);
|
6390
6390
|
}
|
6391
6391
|
return extractResultData;
|
@@ -6471,7 +6471,7 @@ var OpenAIChatIO = /*#__PURE__*/function (_DirectServiceIO11) {
|
|
6471
6471
|
}
|
6472
6472
|
}, _callee61, this);
|
6473
6473
|
}));
|
6474
|
-
function callServiceAPI(
|
6474
|
+
function callServiceAPI(_x105, _x106) {
|
6475
6475
|
return _callServiceAPI18.apply(this, arguments);
|
6476
6476
|
}
|
6477
6477
|
return callServiceAPI;
|
@@ -6502,7 +6502,7 @@ var OpenAIChatIO = /*#__PURE__*/function (_DirectServiceIO11) {
|
|
6502
6502
|
}
|
6503
6503
|
}, _callee62);
|
6504
6504
|
}));
|
6505
|
-
function extractResultData(
|
6505
|
+
function extractResultData(_x107) {
|
6506
6506
|
return _extractResultData22.apply(this, arguments);
|
6507
6507
|
}
|
6508
6508
|
return extractResultData;
|
@@ -6570,7 +6570,7 @@ var CohereChatIO = /*#__PURE__*/function (_CohereIO3) {
|
|
6570
6570
|
}
|
6571
6571
|
}, _callee63, this);
|
6572
6572
|
}));
|
6573
|
-
function callServiceAPI(
|
6573
|
+
function callServiceAPI(_x108, _x109) {
|
6574
6574
|
return _callServiceAPI19.apply(this, arguments);
|
6575
6575
|
}
|
6576
6576
|
return callServiceAPI;
|
@@ -6597,7 +6597,7 @@ var CohereChatIO = /*#__PURE__*/function (_CohereIO3) {
|
|
6597
6597
|
}
|
6598
6598
|
}, _callee64);
|
6599
6599
|
}));
|
6600
|
-
function extractResultData(
|
6600
|
+
function extractResultData(_x110) {
|
6601
6601
|
return _extractResultData23.apply(this, arguments);
|
6602
6602
|
}
|
6603
6603
|
return extractResultData;
|
@@ -6883,8 +6883,9 @@ var HTMLMessageUtils = /*#__PURE__*/function () {
|
|
6883
6883
|
return HTMLMessageUtils;
|
6884
6884
|
}();
|
6885
6885
|
var DEEP_CHAT_TEMPORARY_MESSAGE = "deep-chat-temporary-message",
|
6886
|
+
DEEP_CHAT_SUGGESTION_BUTTON = "deep-chat-suggestion-button",
|
6886
6887
|
DEEP_CHAT_ELEMENTS = {
|
6887
|
-
"deep-chat-
|
6888
|
+
"deep-chat-button": {
|
6888
6889
|
styles: {
|
6889
6890
|
"default": {
|
6890
6891
|
backgroundColor: "white",
|
@@ -6910,6 +6911,16 @@ var HTMLDeepChatElements = /*#__PURE__*/function () {
|
|
6910
6911
|
_classCallCheck(this, HTMLDeepChatElements);
|
6911
6912
|
}
|
6912
6913
|
_createClass(HTMLDeepChatElements, null, [{
|
6914
|
+
key: "applySuggestionEvent",
|
6915
|
+
value: function applySuggestionEvent(e, t) {
|
6916
|
+
setTimeout(function () {
|
6917
|
+
t.addEventListener("click", function () {
|
6918
|
+
var n, s;
|
6919
|
+
(s = e.submitUserMessage) == null || s.call(e, ((n = t.textContent) == null ? void 0 : n.trim()) || "");
|
6920
|
+
});
|
6921
|
+
});
|
6922
|
+
}
|
6923
|
+
}, {
|
6913
6924
|
key: "isElementTemporary",
|
6914
6925
|
value: function isElementTemporary(e) {
|
6915
6926
|
return e ? e.bubbleElement.children[0].classList.contains(DEEP_CHAT_TEMPORARY_MESSAGE) : !1;
|
@@ -6921,23 +6932,13 @@ var HTMLDeepChatElements = /*#__PURE__*/function () {
|
|
6921
6932
|
return e.classList.contains(t);
|
6922
6933
|
});
|
6923
6934
|
}
|
6924
|
-
}, {
|
6925
|
-
key: "applyCustomSuggestionEvent",
|
6926
|
-
value: function applyCustomSuggestionEvent(e, t) {
|
6927
|
-
setTimeout(function () {
|
6928
|
-
t.addEventListener("click", function () {
|
6929
|
-
var n, s;
|
6930
|
-
(s = e.submitUserMessage) == null || s.call(e, ((n = t.textContent) == null ? void 0 : n.trim()) || "");
|
6931
|
-
});
|
6932
|
-
});
|
6933
|
-
}
|
6934
6935
|
}, {
|
6935
6936
|
key: "applyEvents",
|
6936
|
-
value: function applyEvents(e, t
|
6937
|
-
var
|
6938
|
-
Object.keys(
|
6939
|
-
|
6940
|
-
})
|
6937
|
+
value: function applyEvents(e, t) {
|
6938
|
+
var n = DEEP_CHAT_ELEMENTS[t].events;
|
6939
|
+
Object.keys(n || []).forEach(function (s) {
|
6940
|
+
e.addEventListener(s, n == null ? void 0 : n[s]);
|
6941
|
+
});
|
6941
6942
|
}
|
6942
6943
|
}, {
|
6943
6944
|
key: "getProcessedStyles",
|
@@ -6955,13 +6956,17 @@ var HTMLDeepChatElements = /*#__PURE__*/function () {
|
|
6955
6956
|
}, {
|
6956
6957
|
key: "applyDeepChatUtilities",
|
6957
6958
|
value: function applyDeepChatUtilities(e, t, n) {
|
6958
|
-
DEEP_CHAT_ELEMENT_CLASSES.forEach(function (
|
6959
|
-
var
|
6960
|
-
Array.from(
|
6961
|
-
var
|
6962
|
-
HTMLMessageUtils.applyStylesToElement(
|
6959
|
+
DEEP_CHAT_ELEMENT_CLASSES.forEach(function (o) {
|
6960
|
+
var a = n.getElementsByClassName(o);
|
6961
|
+
Array.from(a || []).forEach(function (l) {
|
6962
|
+
var c = HTMLDeepChatElements.getProcessedStyles(t, l, o);
|
6963
|
+
HTMLMessageUtils.applyStylesToElement(l, c), HTMLDeepChatElements.applyEvents(l, o);
|
6963
6964
|
});
|
6964
6965
|
});
|
6966
|
+
var s = n.getElementsByClassName(DEEP_CHAT_SUGGESTION_BUTTON);
|
6967
|
+
Array.from(s).forEach(function (o) {
|
6968
|
+
return HTMLDeepChatElements.applySuggestionEvent(e, o);
|
6969
|
+
});
|
6965
6970
|
}
|
6966
6971
|
}]);
|
6967
6972
|
return HTMLDeepChatElements;
|
@@ -7188,7 +7193,7 @@ var FileMessages = /*#__PURE__*/function () {
|
|
7188
7193
|
}
|
7189
7194
|
}, _callee65);
|
7190
7195
|
}));
|
7191
|
-
function addNewImageMessage(_x112, _x113
|
7196
|
+
function addNewImageMessage(_x111, _x112, _x113) {
|
7192
7197
|
return _addNewImageMessage.apply(this, arguments);
|
7193
7198
|
}
|
7194
7199
|
return addNewImageMessage;
|
@@ -7580,7 +7585,7 @@ var Messages = /*#__PURE__*/function () {
|
|
7580
7585
|
}
|
7581
7586
|
}, _callee66);
|
7582
7587
|
}));
|
7583
|
-
function addMultipleFiles(
|
7588
|
+
function addMultipleFiles(_x114) {
|
7584
7589
|
return _addMultipleFiles.apply(this, arguments);
|
7585
7590
|
}
|
7586
7591
|
return addMultipleFiles;
|
@@ -8492,7 +8497,7 @@ var FileAttachments = /*#__PURE__*/function () {
|
|
8492
8497
|
}
|
8493
8498
|
}, _callee67);
|
8494
8499
|
}));
|
8495
|
-
return function (
|
8500
|
+
return function (_x115) {
|
8496
8501
|
return _ref7.apply(this, arguments);
|
8497
8502
|
};
|
8498
8503
|
}()));
|
@@ -9739,7 +9744,7 @@ var AzureSpeechConfig = /*#__PURE__*/function () {
|
|
9739
9744
|
}
|
9740
9745
|
}, _callee69);
|
9741
9746
|
}));
|
9742
|
-
function getNewSpeechConfig(
|
9747
|
+
function getNewSpeechConfig(_x116, _x117) {
|
9743
9748
|
return _getNewSpeechConfig.apply(this, arguments);
|
9744
9749
|
}
|
9745
9750
|
return getNewSpeechConfig;
|
@@ -9768,7 +9773,7 @@ var AzureSpeechConfig = /*#__PURE__*/function () {
|
|
9768
9773
|
}
|
9769
9774
|
}, _callee70);
|
9770
9775
|
}));
|
9771
|
-
function get(
|
9776
|
+
function get(_x118, _x119) {
|
9772
9777
|
return _get.apply(this, arguments);
|
9773
9778
|
}
|
9774
9779
|
return get;
|
@@ -9879,7 +9884,7 @@ var Azure = /*#__PURE__*/function (_speech_1$Speech) {
|
|
9879
9884
|
}
|
9880
9885
|
}, _callee71, this);
|
9881
9886
|
}));
|
9882
|
-
function startAsync(
|
9887
|
+
function startAsync(_x120) {
|
9883
9888
|
return _startAsync.apply(this, arguments);
|
9884
9889
|
}
|
9885
9890
|
return startAsync;
|
@@ -9913,7 +9918,7 @@ var Azure = /*#__PURE__*/function (_speech_1$Speech) {
|
|
9913
9918
|
}
|
9914
9919
|
}, _callee72, this);
|
9915
9920
|
}));
|
9916
|
-
function instantiateService(
|
9921
|
+
function instantiateService(_x121) {
|
9917
9922
|
return _instantiateService.apply(this, arguments);
|
9918
9923
|
}
|
9919
9924
|
return instantiateService;
|
@@ -10367,7 +10372,7 @@ var SubmitButton = /*#__PURE__*/function (_InputButton4) {
|
|
10367
10372
|
}
|
10368
10373
|
}, _callee73, this);
|
10369
10374
|
}));
|
10370
|
-
function submit(
|
10375
|
+
function submit(_x122, _x123) {
|
10371
10376
|
return _submit.apply(this, arguments);
|
10372
10377
|
}
|
10373
10378
|
return submit;
|