@vendasta/ai-assistants 0.38.0 → 0.39.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/lib/_internal/assistant.api.service.mjs +7 -2
- package/esm2020/lib/_internal/enums/index.mjs +2 -2
- package/esm2020/lib/_internal/enums/model.enum.mjs +24 -0
- package/esm2020/lib/_internal/interfaces/api.interface.mjs +1 -1
- package/esm2020/lib/_internal/interfaces/assistant.interface.mjs +1 -1
- package/esm2020/lib/_internal/interfaces/index.mjs +1 -1
- package/esm2020/lib/_internal/interfaces/model.interface.mjs +8 -0
- package/esm2020/lib/_internal/objects/api.mjs +133 -37
- package/esm2020/lib/_internal/objects/assistant.mjs +8 -1
- package/esm2020/lib/_internal/objects/index.mjs +3 -2
- package/esm2020/lib/_internal/objects/model.mjs +46 -0
- package/fesm2015/vendasta-ai-assistants.mjs +220 -63
- package/fesm2015/vendasta-ai-assistants.mjs.map +1 -1
- package/fesm2020/vendasta-ai-assistants.mjs +220 -63
- package/fesm2020/vendasta-ai-assistants.mjs.map +1 -1
- package/lib/_internal/assistant.api.service.d.ts +3 -2
- package/lib/_internal/enums/index.d.ts +1 -1
- package/lib/_internal/enums/model.enum.d.ts +15 -0
- package/lib/_internal/interfaces/api.interface.d.ts +28 -14
- package/lib/_internal/interfaces/assistant.interface.d.ts +2 -0
- package/lib/_internal/interfaces/index.d.ts +2 -1
- package/lib/_internal/interfaces/model.interface.d.ts +8 -0
- package/lib/_internal/objects/api.d.ts +42 -16
- package/lib/_internal/objects/assistant.d.ts +2 -0
- package/lib/_internal/objects/index.d.ts +2 -1
- package/lib/_internal/objects/model.d.ts +13 -0
- package/package.json +1 -1
- package/esm2020/lib/_internal/enums/api.enum.mjs +0 -18
- package/lib/_internal/enums/api.enum.d.ts +0 -10
|
@@ -68,6 +68,30 @@ var GoalType;
|
|
|
68
68
|
GoalType[GoalType["GOAL_TYPE_CUSTOM"] = 4] = "GOAL_TYPE_CUSTOM";
|
|
69
69
|
})(GoalType || (GoalType = {}));
|
|
70
70
|
|
|
71
|
+
// *********************************
|
|
72
|
+
// Code generated by sdkgen
|
|
73
|
+
// DO NOT EDIT!.
|
|
74
|
+
//
|
|
75
|
+
// Enums.
|
|
76
|
+
// *********************************
|
|
77
|
+
var ModelType;
|
|
78
|
+
(function (ModelType) {
|
|
79
|
+
ModelType[ModelType["TYPE_UNSET"] = 0] = "TYPE_UNSET";
|
|
80
|
+
ModelType[ModelType["TYPE_LARGE_LANGUAGE_MODEL"] = 1] = "TYPE_LARGE_LANGUAGE_MODEL";
|
|
81
|
+
ModelType[ModelType["TYPE_SPEECH_TO_TEXT"] = 2] = "TYPE_SPEECH_TO_TEXT";
|
|
82
|
+
ModelType[ModelType["TYPE_TEXT_TO_SPEECH"] = 3] = "TYPE_TEXT_TO_SPEECH";
|
|
83
|
+
ModelType[ModelType["TYPE_SPEECH_TO_SPEECH"] = 4] = "TYPE_SPEECH_TO_SPEECH";
|
|
84
|
+
ModelType[ModelType["TYPE_TEXT_TO_IMAGE"] = 5] = "TYPE_TEXT_TO_IMAGE";
|
|
85
|
+
ModelType[ModelType["TYPE_TEXT_TO_VIDEO"] = 6] = "TYPE_TEXT_TO_VIDEO";
|
|
86
|
+
})(ModelType || (ModelType = {}));
|
|
87
|
+
var ModelVendor;
|
|
88
|
+
(function (ModelVendor) {
|
|
89
|
+
ModelVendor[ModelVendor["VENDOR_UNSET"] = 0] = "VENDOR_UNSET";
|
|
90
|
+
ModelVendor[ModelVendor["VENDOR_OPENAI"] = 1] = "VENDOR_OPENAI";
|
|
91
|
+
ModelVendor[ModelVendor["VENDOR_GOOGLE"] = 2] = "VENDOR_GOOGLE";
|
|
92
|
+
ModelVendor[ModelVendor["VENDOR_DEEPGRAM"] = 3] = "VENDOR_DEEPGRAM";
|
|
93
|
+
})(ModelVendor || (ModelVendor = {}));
|
|
94
|
+
|
|
71
95
|
// *********************************
|
|
72
96
|
// Code generated by sdkgen
|
|
73
97
|
// DO NOT EDIT!.
|
|
@@ -138,24 +162,6 @@ var SortDirection;
|
|
|
138
162
|
SortDirection[SortDirection["SORT_DIRECTION_DESCENDING"] = 2] = "SORT_DIRECTION_DESCENDING";
|
|
139
163
|
})(SortDirection || (SortDirection = {}));
|
|
140
164
|
|
|
141
|
-
// *********************************
|
|
142
|
-
// Code generated by sdkgen
|
|
143
|
-
// DO NOT EDIT!.
|
|
144
|
-
//
|
|
145
|
-
// Enums.
|
|
146
|
-
// *********************************
|
|
147
|
-
var GenerateChatAnswerRequestModel;
|
|
148
|
-
(function (GenerateChatAnswerRequestModel) {
|
|
149
|
-
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_NOT_SET"] = 0] = "MODEL_NOT_SET";
|
|
150
|
-
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4OMNI"] = 1] = "MODEL_OPENAI_GPT_4OMNI";
|
|
151
|
-
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4OMNI_MINI"] = 2] = "MODEL_OPENAI_GPT_4OMNI_MINI";
|
|
152
|
-
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4DOT1"] = 3] = "MODEL_OPENAI_GPT_4DOT1";
|
|
153
|
-
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4DOT1_MINI"] = 4] = "MODEL_OPENAI_GPT_4DOT1_MINI";
|
|
154
|
-
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4DOT1_NANO"] = 5] = "MODEL_OPENAI_GPT_4DOT1_NANO";
|
|
155
|
-
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_GOOGLE_GEMINI_2DOT5_PRO_PREVIEW"] = 6] = "MODEL_GOOGLE_GEMINI_2DOT5_PRO_PREVIEW";
|
|
156
|
-
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_GOOGLE_GEMINI_2DOT5_FLASH_PREVIEW"] = 7] = "MODEL_GOOGLE_GEMINI_2DOT5_FLASH_PREVIEW";
|
|
157
|
-
})(GenerateChatAnswerRequestModel || (GenerateChatAnswerRequestModel = {}));
|
|
158
|
-
|
|
159
165
|
// *********************************
|
|
160
166
|
// Code generated by sdkgen
|
|
161
167
|
// DO NOT EDIT!.
|
|
@@ -163,7 +169,7 @@ var GenerateChatAnswerRequestModel;
|
|
|
163
169
|
// Enums Index.
|
|
164
170
|
// *********************************
|
|
165
171
|
|
|
166
|
-
function enumStringToValue$
|
|
172
|
+
function enumStringToValue$d(enumRef, value) {
|
|
167
173
|
if (typeof value === 'number') {
|
|
168
174
|
return value;
|
|
169
175
|
}
|
|
@@ -285,7 +291,7 @@ class NamespaceSystemNamespace {
|
|
|
285
291
|
}
|
|
286
292
|
}
|
|
287
293
|
|
|
288
|
-
function enumStringToValue$
|
|
294
|
+
function enumStringToValue$c(enumRef, value) {
|
|
289
295
|
if (typeof value === 'number') {
|
|
290
296
|
return value;
|
|
291
297
|
}
|
|
@@ -445,7 +451,7 @@ class FunctionParameter {
|
|
|
445
451
|
m.items = FunctionParameter.fromProto(proto.items);
|
|
446
452
|
}
|
|
447
453
|
if (proto.location) {
|
|
448
|
-
m.location = enumStringToValue$
|
|
454
|
+
m.location = enumStringToValue$c(FunctionParameterParameterLocation, proto.location);
|
|
449
455
|
}
|
|
450
456
|
return m;
|
|
451
457
|
}
|
|
@@ -519,7 +525,7 @@ class FunctionAuthStrategyUnspecifiedFunctionAuthStrategy {
|
|
|
519
525
|
}
|
|
520
526
|
}
|
|
521
527
|
|
|
522
|
-
function enumStringToValue$
|
|
528
|
+
function enumStringToValue$b(enumRef, value) {
|
|
523
529
|
if (typeof value === 'number') {
|
|
524
530
|
return value;
|
|
525
531
|
}
|
|
@@ -722,7 +728,7 @@ class PromptVersion {
|
|
|
722
728
|
}
|
|
723
729
|
}
|
|
724
730
|
|
|
725
|
-
function enumStringToValue$
|
|
731
|
+
function enumStringToValue$a(enumRef, value) {
|
|
726
732
|
if (typeof value === 'number') {
|
|
727
733
|
return value;
|
|
728
734
|
}
|
|
@@ -736,7 +742,7 @@ class Goal {
|
|
|
736
742
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
737
743
|
}
|
|
738
744
|
if (proto.type) {
|
|
739
|
-
m.type = enumStringToValue$
|
|
745
|
+
m.type = enumStringToValue$a(GoalType, proto.type);
|
|
740
746
|
}
|
|
741
747
|
if (proto.promptModules) {
|
|
742
748
|
m.promptModules = proto.promptModules.map(PromptModule.fromProto);
|
|
@@ -748,7 +754,7 @@ class Goal {
|
|
|
748
754
|
m.updated = new Date(proto.updated);
|
|
749
755
|
}
|
|
750
756
|
if (proto.supportedChannels) {
|
|
751
|
-
m.supportedChannels = proto.supportedChannels.map((v) => enumStringToValue$
|
|
757
|
+
m.supportedChannels = proto.supportedChannels.map((v) => enumStringToValue$a(GoalChannel, v));
|
|
752
758
|
}
|
|
753
759
|
return m;
|
|
754
760
|
}
|
|
@@ -823,7 +829,7 @@ class GoalKey {
|
|
|
823
829
|
}
|
|
824
830
|
}
|
|
825
831
|
|
|
826
|
-
function enumStringToValue$
|
|
832
|
+
function enumStringToValue$9(enumRef, value) {
|
|
827
833
|
if (typeof value === 'number') {
|
|
828
834
|
return value;
|
|
829
835
|
}
|
|
@@ -853,6 +859,51 @@ class KeyValuePair {
|
|
|
853
859
|
}
|
|
854
860
|
}
|
|
855
861
|
|
|
862
|
+
function enumStringToValue$8(enumRef, value) {
|
|
863
|
+
if (typeof value === 'number') {
|
|
864
|
+
return value;
|
|
865
|
+
}
|
|
866
|
+
return enumRef[value];
|
|
867
|
+
}
|
|
868
|
+
class Model {
|
|
869
|
+
static fromProto(proto) {
|
|
870
|
+
let m = new Model();
|
|
871
|
+
m = Object.assign(m, proto);
|
|
872
|
+
if (proto.vendor) {
|
|
873
|
+
m.vendor = enumStringToValue$8(ModelVendor, proto.vendor);
|
|
874
|
+
}
|
|
875
|
+
if (proto.type) {
|
|
876
|
+
m.type = enumStringToValue$8(ModelType, proto.type);
|
|
877
|
+
}
|
|
878
|
+
return m;
|
|
879
|
+
}
|
|
880
|
+
constructor(kwargs) {
|
|
881
|
+
if (!kwargs) {
|
|
882
|
+
return;
|
|
883
|
+
}
|
|
884
|
+
Object.assign(this, kwargs);
|
|
885
|
+
}
|
|
886
|
+
toApiJson() {
|
|
887
|
+
const toReturn = {};
|
|
888
|
+
if (typeof this.id !== 'undefined') {
|
|
889
|
+
toReturn['id'] = this.id;
|
|
890
|
+
}
|
|
891
|
+
if (typeof this.vendor !== 'undefined') {
|
|
892
|
+
toReturn['vendor'] = this.vendor;
|
|
893
|
+
}
|
|
894
|
+
if (typeof this.type !== 'undefined') {
|
|
895
|
+
toReturn['type'] = this.type;
|
|
896
|
+
}
|
|
897
|
+
if (typeof this.name !== 'undefined') {
|
|
898
|
+
toReturn['name'] = this.name;
|
|
899
|
+
}
|
|
900
|
+
if (typeof this.recommended !== 'undefined') {
|
|
901
|
+
toReturn['recommended'] = this.recommended;
|
|
902
|
+
}
|
|
903
|
+
return toReturn;
|
|
904
|
+
}
|
|
905
|
+
}
|
|
906
|
+
|
|
856
907
|
function enumStringToValue$7(enumRef, value) {
|
|
857
908
|
if (typeof value === 'number') {
|
|
858
909
|
return value;
|
|
@@ -948,6 +999,9 @@ class Config {
|
|
|
948
999
|
if (proto.voiceConfig) {
|
|
949
1000
|
m.voiceConfig = ConfigVoiceConfig.fromProto(proto.voiceConfig);
|
|
950
1001
|
}
|
|
1002
|
+
if (proto.models) {
|
|
1003
|
+
m.models = proto.models.map(Model.fromProto);
|
|
1004
|
+
}
|
|
951
1005
|
return m;
|
|
952
1006
|
}
|
|
953
1007
|
constructor(kwargs) {
|
|
@@ -964,6 +1018,9 @@ class Config {
|
|
|
964
1018
|
if (typeof this.voiceConfig !== 'undefined' && this.voiceConfig !== null) {
|
|
965
1019
|
toReturn['voiceConfig'] = 'toApiJson' in this.voiceConfig ? this.voiceConfig.toApiJson() : this.voiceConfig;
|
|
966
1020
|
}
|
|
1021
|
+
if (typeof this.models !== 'undefined' && this.models !== null) {
|
|
1022
|
+
toReturn['models'] = 'toApiJson' in this.models ? this.models.toApiJson() : this.models;
|
|
1023
|
+
}
|
|
967
1024
|
return toReturn;
|
|
968
1025
|
}
|
|
969
1026
|
}
|
|
@@ -2534,21 +2591,12 @@ class ExecuteFunctionResponse {
|
|
|
2534
2591
|
return toReturn;
|
|
2535
2592
|
}
|
|
2536
2593
|
}
|
|
2537
|
-
class
|
|
2594
|
+
class ListAllAssistantsAssociatedToConnectionRequestFilters {
|
|
2538
2595
|
static fromProto(proto) {
|
|
2539
|
-
let m = new
|
|
2596
|
+
let m = new ListAllAssistantsAssociatedToConnectionRequestFilters();
|
|
2540
2597
|
m = Object.assign(m, proto);
|
|
2541
|
-
if (proto.namespace) {
|
|
2542
|
-
m.namespace = Namespace.fromProto(proto.namespace);
|
|
2543
|
-
}
|
|
2544
2598
|
if (proto.type) {
|
|
2545
|
-
m.type = enumStringToValue(
|
|
2546
|
-
}
|
|
2547
|
-
if (proto.supportedChannels) {
|
|
2548
|
-
m.supportedChannels = proto.supportedChannels.map((v) => enumStringToValue(GoalChannel, v));
|
|
2549
|
-
}
|
|
2550
|
-
if (proto.namespaces) {
|
|
2551
|
-
m.namespaces = proto.namespaces.map(Namespace.fromProto);
|
|
2599
|
+
m.type = enumStringToValue(AssistantType, proto.type);
|
|
2552
2600
|
}
|
|
2553
2601
|
return m;
|
|
2554
2602
|
}
|
|
@@ -2560,18 +2608,9 @@ class ListGoalsRequestFilters {
|
|
|
2560
2608
|
}
|
|
2561
2609
|
toApiJson() {
|
|
2562
2610
|
const toReturn = {};
|
|
2563
|
-
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
2564
|
-
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
2565
|
-
}
|
|
2566
2611
|
if (typeof this.type !== 'undefined') {
|
|
2567
2612
|
toReturn['type'] = this.type;
|
|
2568
2613
|
}
|
|
2569
|
-
if (typeof this.supportedChannels !== 'undefined') {
|
|
2570
|
-
toReturn['supportedChannels'] = this.supportedChannels;
|
|
2571
|
-
}
|
|
2572
|
-
if (typeof this.namespaces !== 'undefined' && this.namespaces !== null) {
|
|
2573
|
-
toReturn['namespaces'] = 'toApiJson' in this.namespaces ? this.namespaces.toApiJson() : this.namespaces;
|
|
2574
|
-
}
|
|
2575
2614
|
return toReturn;
|
|
2576
2615
|
}
|
|
2577
2616
|
}
|
|
@@ -2627,12 +2666,44 @@ class ListFunctionRequestFilters {
|
|
|
2627
2666
|
return toReturn;
|
|
2628
2667
|
}
|
|
2629
2668
|
}
|
|
2630
|
-
class
|
|
2669
|
+
class ListPromptModuleRequestFilters {
|
|
2631
2670
|
static fromProto(proto) {
|
|
2632
|
-
let m = new
|
|
2671
|
+
let m = new ListPromptModuleRequestFilters();
|
|
2672
|
+
m = Object.assign(m, proto);
|
|
2673
|
+
if (proto.namespace) {
|
|
2674
|
+
m.namespace = Namespace.fromProto(proto.namespace);
|
|
2675
|
+
}
|
|
2676
|
+
return m;
|
|
2677
|
+
}
|
|
2678
|
+
constructor(kwargs) {
|
|
2679
|
+
if (!kwargs) {
|
|
2680
|
+
return;
|
|
2681
|
+
}
|
|
2682
|
+
Object.assign(this, kwargs);
|
|
2683
|
+
}
|
|
2684
|
+
toApiJson() {
|
|
2685
|
+
const toReturn = {};
|
|
2686
|
+
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
2687
|
+
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
2688
|
+
}
|
|
2689
|
+
return toReturn;
|
|
2690
|
+
}
|
|
2691
|
+
}
|
|
2692
|
+
class ListGoalsRequestFilters {
|
|
2693
|
+
static fromProto(proto) {
|
|
2694
|
+
let m = new ListGoalsRequestFilters();
|
|
2633
2695
|
m = Object.assign(m, proto);
|
|
2696
|
+
if (proto.namespace) {
|
|
2697
|
+
m.namespace = Namespace.fromProto(proto.namespace);
|
|
2698
|
+
}
|
|
2634
2699
|
if (proto.type) {
|
|
2635
|
-
m.type = enumStringToValue(
|
|
2700
|
+
m.type = enumStringToValue(GoalType, proto.type);
|
|
2701
|
+
}
|
|
2702
|
+
if (proto.supportedChannels) {
|
|
2703
|
+
m.supportedChannels = proto.supportedChannels.map((v) => enumStringToValue(GoalChannel, v));
|
|
2704
|
+
}
|
|
2705
|
+
if (proto.namespaces) {
|
|
2706
|
+
m.namespaces = proto.namespaces.map(Namespace.fromProto);
|
|
2636
2707
|
}
|
|
2637
2708
|
return m;
|
|
2638
2709
|
}
|
|
@@ -2644,9 +2715,18 @@ class ListAllAssistantsAssociatedToConnectionRequestFilters {
|
|
|
2644
2715
|
}
|
|
2645
2716
|
toApiJson() {
|
|
2646
2717
|
const toReturn = {};
|
|
2718
|
+
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
2719
|
+
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
2720
|
+
}
|
|
2647
2721
|
if (typeof this.type !== 'undefined') {
|
|
2648
2722
|
toReturn['type'] = this.type;
|
|
2649
2723
|
}
|
|
2724
|
+
if (typeof this.supportedChannels !== 'undefined') {
|
|
2725
|
+
toReturn['supportedChannels'] = this.supportedChannels;
|
|
2726
|
+
}
|
|
2727
|
+
if (typeof this.namespaces !== 'undefined' && this.namespaces !== null) {
|
|
2728
|
+
toReturn['namespaces'] = 'toApiJson' in this.namespaces ? this.namespaces.toApiJson() : this.namespaces;
|
|
2729
|
+
}
|
|
2650
2730
|
return toReturn;
|
|
2651
2731
|
}
|
|
2652
2732
|
}
|
|
@@ -2679,12 +2759,15 @@ class ListAssistantRequestFilters {
|
|
|
2679
2759
|
return toReturn;
|
|
2680
2760
|
}
|
|
2681
2761
|
}
|
|
2682
|
-
class
|
|
2762
|
+
class ListAvailableModelsRequestFilters {
|
|
2683
2763
|
static fromProto(proto) {
|
|
2684
|
-
let m = new
|
|
2764
|
+
let m = new ListAvailableModelsRequestFilters();
|
|
2685
2765
|
m = Object.assign(m, proto);
|
|
2686
|
-
if (proto.
|
|
2687
|
-
m.
|
|
2766
|
+
if (proto.vendor) {
|
|
2767
|
+
m.vendor = proto.vendor.map((v) => enumStringToValue(ModelVendor, v));
|
|
2768
|
+
}
|
|
2769
|
+
if (proto.type) {
|
|
2770
|
+
m.type = proto.type.map((v) => enumStringToValue(ModelType, v));
|
|
2688
2771
|
}
|
|
2689
2772
|
return m;
|
|
2690
2773
|
}
|
|
@@ -2696,8 +2779,11 @@ class ListPromptModuleRequestFilters {
|
|
|
2696
2779
|
}
|
|
2697
2780
|
toApiJson() {
|
|
2698
2781
|
const toReturn = {};
|
|
2699
|
-
if (typeof this.
|
|
2700
|
-
toReturn['
|
|
2782
|
+
if (typeof this.vendor !== 'undefined') {
|
|
2783
|
+
toReturn['vendor'] = this.vendor;
|
|
2784
|
+
}
|
|
2785
|
+
if (typeof this.type !== 'undefined') {
|
|
2786
|
+
toReturn['type'] = this.type;
|
|
2701
2787
|
}
|
|
2702
2788
|
return toReturn;
|
|
2703
2789
|
}
|
|
@@ -2797,6 +2883,9 @@ class GetAssistantRequest {
|
|
|
2797
2883
|
if (proto.namespace) {
|
|
2798
2884
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
2799
2885
|
}
|
|
2886
|
+
if (proto.options) {
|
|
2887
|
+
m.options = GetAssistantRequestOptions.fromProto(proto.options);
|
|
2888
|
+
}
|
|
2800
2889
|
return m;
|
|
2801
2890
|
}
|
|
2802
2891
|
constructor(kwargs) {
|
|
@@ -2813,6 +2902,9 @@ class GetAssistantRequest {
|
|
|
2813
2902
|
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
2814
2903
|
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
2815
2904
|
}
|
|
2905
|
+
if (typeof this.options !== 'undefined' && this.options !== null) {
|
|
2906
|
+
toReturn['options'] = 'toApiJson' in this.options ? this.options.toApiJson() : this.options;
|
|
2907
|
+
}
|
|
2816
2908
|
return toReturn;
|
|
2817
2909
|
}
|
|
2818
2910
|
}
|
|
@@ -3727,6 +3819,52 @@ class ListAssistantResponse {
|
|
|
3727
3819
|
return toReturn;
|
|
3728
3820
|
}
|
|
3729
3821
|
}
|
|
3822
|
+
class ListAvailableModelsRequest {
|
|
3823
|
+
static fromProto(proto) {
|
|
3824
|
+
let m = new ListAvailableModelsRequest();
|
|
3825
|
+
m = Object.assign(m, proto);
|
|
3826
|
+
if (proto.filters) {
|
|
3827
|
+
m.filters = ListAvailableModelsRequestFilters.fromProto(proto.filters);
|
|
3828
|
+
}
|
|
3829
|
+
return m;
|
|
3830
|
+
}
|
|
3831
|
+
constructor(kwargs) {
|
|
3832
|
+
if (!kwargs) {
|
|
3833
|
+
return;
|
|
3834
|
+
}
|
|
3835
|
+
Object.assign(this, kwargs);
|
|
3836
|
+
}
|
|
3837
|
+
toApiJson() {
|
|
3838
|
+
const toReturn = {};
|
|
3839
|
+
if (typeof this.filters !== 'undefined' && this.filters !== null) {
|
|
3840
|
+
toReturn['filters'] = 'toApiJson' in this.filters ? this.filters.toApiJson() : this.filters;
|
|
3841
|
+
}
|
|
3842
|
+
return toReturn;
|
|
3843
|
+
}
|
|
3844
|
+
}
|
|
3845
|
+
class ListAvailableModelsResponse {
|
|
3846
|
+
static fromProto(proto) {
|
|
3847
|
+
let m = new ListAvailableModelsResponse();
|
|
3848
|
+
m = Object.assign(m, proto);
|
|
3849
|
+
if (proto.models) {
|
|
3850
|
+
m.models = proto.models.map(Model.fromProto);
|
|
3851
|
+
}
|
|
3852
|
+
return m;
|
|
3853
|
+
}
|
|
3854
|
+
constructor(kwargs) {
|
|
3855
|
+
if (!kwargs) {
|
|
3856
|
+
return;
|
|
3857
|
+
}
|
|
3858
|
+
Object.assign(this, kwargs);
|
|
3859
|
+
}
|
|
3860
|
+
toApiJson() {
|
|
3861
|
+
const toReturn = {};
|
|
3862
|
+
if (typeof this.models !== 'undefined' && this.models !== null) {
|
|
3863
|
+
toReturn['models'] = 'toApiJson' in this.models ? this.models.toApiJson() : this.models;
|
|
3864
|
+
}
|
|
3865
|
+
return toReturn;
|
|
3866
|
+
}
|
|
3867
|
+
}
|
|
3730
3868
|
class ListConnectionsRequest {
|
|
3731
3869
|
static fromProto(proto) {
|
|
3732
3870
|
let m = new ListConnectionsRequest();
|
|
@@ -4149,9 +4287,6 @@ class GenerateChatAnswerRequestOptions {
|
|
|
4149
4287
|
if (proto.maxTokens) {
|
|
4150
4288
|
m.maxTokens = parseInt(proto.maxTokens, 10);
|
|
4151
4289
|
}
|
|
4152
|
-
if (proto.model) {
|
|
4153
|
-
m.model = enumStringToValue(GenerateChatAnswerRequestModel, proto.model);
|
|
4154
|
-
}
|
|
4155
4290
|
return m;
|
|
4156
4291
|
}
|
|
4157
4292
|
constructor(kwargs) {
|
|
@@ -4171,9 +4306,6 @@ class GenerateChatAnswerRequestOptions {
|
|
|
4171
4306
|
if (typeof this.maxTokens !== 'undefined') {
|
|
4172
4307
|
toReturn['maxTokens'] = this.maxTokens;
|
|
4173
4308
|
}
|
|
4174
|
-
if (typeof this.model !== 'undefined') {
|
|
4175
|
-
toReturn['model'] = this.model;
|
|
4176
|
-
}
|
|
4177
4309
|
return toReturn;
|
|
4178
4310
|
}
|
|
4179
4311
|
}
|
|
@@ -4197,6 +4329,26 @@ class CreateAssistantRequestOptions {
|
|
|
4197
4329
|
return toReturn;
|
|
4198
4330
|
}
|
|
4199
4331
|
}
|
|
4332
|
+
class GetAssistantRequestOptions {
|
|
4333
|
+
static fromProto(proto) {
|
|
4334
|
+
let m = new GetAssistantRequestOptions();
|
|
4335
|
+
m = Object.assign(m, proto);
|
|
4336
|
+
return m;
|
|
4337
|
+
}
|
|
4338
|
+
constructor(kwargs) {
|
|
4339
|
+
if (!kwargs) {
|
|
4340
|
+
return;
|
|
4341
|
+
}
|
|
4342
|
+
Object.assign(this, kwargs);
|
|
4343
|
+
}
|
|
4344
|
+
toApiJson() {
|
|
4345
|
+
const toReturn = {};
|
|
4346
|
+
if (typeof this.skipGoalsHydration !== 'undefined') {
|
|
4347
|
+
toReturn['skipGoalsHydration'] = this.skipGoalsHydration;
|
|
4348
|
+
}
|
|
4349
|
+
return toReturn;
|
|
4350
|
+
}
|
|
4351
|
+
}
|
|
4200
4352
|
class CreatePromptModuleVersionRequestOptions {
|
|
4201
4353
|
static fromProto(proto) {
|
|
4202
4354
|
let m = new CreatePromptModuleVersionRequestOptions();
|
|
@@ -4582,6 +4734,11 @@ class AssistantApiService {
|
|
|
4582
4734
|
return this.http.post(this._host + "/ai_assistants.v1alpha1.AssistantService/ExecuteFunction", request.toApiJson(), this.apiOptions())
|
|
4583
4735
|
.pipe(map(resp => ExecuteFunctionResponse.fromProto(resp)));
|
|
4584
4736
|
}
|
|
4737
|
+
listAvailableModels(r) {
|
|
4738
|
+
const request = (r.toApiJson) ? r : new ListAvailableModelsRequest(r);
|
|
4739
|
+
return this.http.post(this._host + "/ai_assistants.v1alpha1.AssistantService/ListAvailableModels", request.toApiJson(), this.apiOptions())
|
|
4740
|
+
.pipe(map(resp => ListAvailableModelsResponse.fromProto(resp)));
|
|
4741
|
+
}
|
|
4585
4742
|
}
|
|
4586
4743
|
AssistantApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AssistantApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
4587
4744
|
AssistantApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AssistantApiService, providedIn: 'root' });
|
|
@@ -4981,5 +5138,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
4981
5138
|
* Generated bundle index. Do not edit.
|
|
4982
5139
|
*/
|
|
4983
5140
|
|
|
4984
|
-
export { Access, Assistant, AssistantApiService, AssistantKey, AssistantType, BuildDefaultAssistantRequest, BuildDefaultAssistantResponse, CancelTestRunRequest, ChatAnswerFunctionExecutionJob, ChatAnswerFunctionExecutionJobResult, ChatAnswerFunctionExecutionJobStatus, ChatChannel, ChatMessage, ChatMessageRole, ChatUserInfo, Config, ConfigInboxConfig, ConfigVoiceConfig, ConfigurableGoal, Connection, ConnectionApiService, ConnectionKey, ContextInfo, CreateAssistantRequest, CreateAssistantRequestOptions, CreateAssistantResponse, CreateGoalRequest, CreateGoalResponse, CreatePromptModuleRequest, CreatePromptModuleResponse, CreatePromptModuleVersionRequest, CreatePromptModuleVersionRequestOptions, CreatePromptRequest, DeepgramConfig, DeleteAssistantRequest, DeleteConnectionRequest, DeleteFunctionRequest, DeleteGoalRequest, DeletePromptModuleRequest, DeletePromptRequest, DeleteTestCasesRequest, DeployPromptModuleRequest, DeployPromptRequest, ExecuteFunctionRequest, ExecuteFunctionResponse, FieldMask, Function, FunctionApiService, FunctionAuthStrategy, FunctionAuthStrategyPlatformManagedFunctionAuthStrategy, FunctionAuthStrategyUnspecifiedFunctionAuthStrategy, FunctionHeader, FunctionKey, FunctionParameter, FunctionParameterParameterLocation, GenerateChatAnswerRequest,
|
|
5141
|
+
export { Access, Assistant, AssistantApiService, AssistantKey, AssistantType, BuildDefaultAssistantRequest, BuildDefaultAssistantResponse, CancelTestRunRequest, ChatAnswerFunctionExecutionJob, ChatAnswerFunctionExecutionJobResult, ChatAnswerFunctionExecutionJobStatus, ChatChannel, ChatMessage, ChatMessageRole, ChatUserInfo, Config, ConfigInboxConfig, ConfigVoiceConfig, ConfigurableGoal, Connection, ConnectionApiService, ConnectionKey, ContextInfo, CreateAssistantRequest, CreateAssistantRequestOptions, CreateAssistantResponse, CreateGoalRequest, CreateGoalResponse, CreatePromptModuleRequest, CreatePromptModuleResponse, CreatePromptModuleVersionRequest, CreatePromptModuleVersionRequestOptions, CreatePromptRequest, DeepgramConfig, DeleteAssistantRequest, DeleteConnectionRequest, DeleteFunctionRequest, DeleteGoalRequest, DeletePromptModuleRequest, DeletePromptRequest, DeleteTestCasesRequest, DeployPromptModuleRequest, DeployPromptRequest, ExecuteFunctionRequest, ExecuteFunctionResponse, FieldMask, Function, FunctionApiService, FunctionAuthStrategy, FunctionAuthStrategyPlatformManagedFunctionAuthStrategy, FunctionAuthStrategyUnspecifiedFunctionAuthStrategy, FunctionHeader, FunctionKey, FunctionParameter, FunctionParameterParameterLocation, GenerateChatAnswerRequest, GenerateChatAnswerRequestOptions, GenerateChatAnswerResponse, GetAssistantRequest, GetAssistantRequestOptions, GetAssistantResponse, GetChatAnswerFunctionExecutionJobRequest, GetChatAnswerFunctionExecutionJobResponse, GetConnectionRequest, GetConnectionResponse, GetDeployedPromptModuleVersionRequest, GetDeployedPromptModuleVersionResponse, GetDeployedPromptVersionRequest, GetDeployedPromptVersionResponse, GetFunctionRequest, GetFunctionResponse, GetGoalRequest, GetGoalResponse, GetHydratedDeployedPromptModuleVersionRequest, GetHydratedDeployedPromptModuleVersionResponse, GetMultiDeployedPromptVersionRequest, GetMultiDeployedPromptVersionResponse, GetMultiFunctionRequest, GetMultiFunctionResponse, GetMultiGoalRequest, GetMultiGoalResponse, GetMultiHydratedDeployedPromptModuleVersionRequest, GetMultiHydratedDeployedPromptModuleVersionResponse, GetPromptModuleRequest, GetPromptModuleResponse, GetPromptModuleVersionRequest, GetPromptModuleVersionResponse, GetPromptRequest, GetPromptResponse, GetPromptVersionRequest, GetPromptVersionResponse, GetTestRunRequest, GetTestRunResponse, Goal, GoalApiService, GoalChannel, GoalKey, GoalType, GoalsDisabledForAccountGroupRequest, GoalsDisabledForAccountGroupResponse, HostService, IntegrationTestApiService, KeyValuePair, ListAllAssistantsAssociatedToConnectionRequest, ListAllAssistantsAssociatedToConnectionRequestFilters, ListAllAssistantsAssociatedToConnectionResponse, ListAssistantRequest, ListAssistantRequestFilters, ListAssistantResponse, ListAvailableModelsRequest, ListAvailableModelsRequestFilters, ListAvailableModelsResponse, ListConnectionsRequest, ListConnectionsRequestFilters, ListConnectionsResponse, ListFunctionRequest, ListFunctionRequestFilters, ListFunctionResponse, ListGoalsRequest, ListGoalsRequestFilters, ListGoalsResponse, ListPromptModuleRequest, ListPromptModuleRequestFilters, ListPromptModuleResponse, ListPromptModuleVersionsRequest, ListPromptModuleVersionsResponse, ListPromptRequest, ListPromptResponse, ListPromptVersionsRequest, ListPromptVersionsResponse, ListTestCasesByAssistantRequest, ListTestCasesByAssistantResponse, ListTestRunsByAssistantRequest, ListTestRunsByAssistantResponse, Model, ModelConfig, ModelType, ModelVendor, Namespace, NamespaceAccountGroupNamespace, NamespaceGlobalNamespace, NamespacePartnerNamespace, NamespaceSystemNamespace, OpenAIRealtimeConfig, OpenAIRealtimeConfigTurnDetection, PagedRequestOptions, PagedResponseMetadata, Prompt, PromptApiService, PromptModule, PromptModuleApiService, PromptModuleKey, PromptModuleVersion, PromptVersion, RunTestsRequest, RunTestsResponse, SetAssistantConnectionsRequest, SetAssistantConnectionsRequestConnectionState, SortDirection, SortOptions, TestCase, TestResult, TestRun, UpdateAssistantRequest, UpdateGoalRequest, UpdatePromptModuleRequest, UpdatePromptRequest, UpsertAssistantRequest, UpsertAssistantRequestOptions, UpsertAssistantResponse, UpsertConnectionRequest, UpsertFunctionRequest, UpsertGoalRequest, UpsertTestCasesRequest, VendorModel };
|
|
4985
5142
|
//# sourceMappingURL=vendasta-ai-assistants.mjs.map
|