@vendasta/ai-assistants 0.37.0 → 0.38.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/enums/api.enum.mjs +18 -0
- package/esm2020/lib/_internal/enums/index.mjs +3 -1
- package/esm2020/lib/_internal/enums/integration-tests.enum.mjs +13 -0
- package/esm2020/lib/_internal/integration-test.api.service.mjs +6 -2
- package/esm2020/lib/_internal/interfaces/api.interface.mjs +1 -1
- package/esm2020/lib/_internal/interfaces/index.mjs +1 -1
- package/esm2020/lib/_internal/interfaces/integration-tests.interface.mjs +1 -1
- package/esm2020/lib/_internal/objects/api.mjs +7 -1
- package/esm2020/lib/_internal/objects/index.mjs +2 -2
- package/esm2020/lib/_internal/objects/integration-tests.mjs +63 -1
- package/fesm2015/vendasta-ai-assistants.mjs +103 -1
- package/fesm2015/vendasta-ai-assistants.mjs.map +1 -1
- package/fesm2020/vendasta-ai-assistants.mjs +103 -1
- package/fesm2020/vendasta-ai-assistants.mjs.map +1 -1
- package/lib/_internal/enums/api.enum.d.ts +10 -0
- package/lib/_internal/enums/index.d.ts +2 -0
- package/lib/_internal/enums/integration-tests.enum.d.ts +5 -0
- package/lib/_internal/integration-test.api.service.d.ts +3 -2
- package/lib/_internal/interfaces/api.interface.d.ts +1 -0
- package/lib/_internal/interfaces/index.d.ts +1 -1
- package/lib/_internal/interfaces/integration-tests.interface.d.ts +11 -0
- package/lib/_internal/objects/api.d.ts +1 -0
- package/lib/_internal/objects/index.d.ts +1 -1
- package/lib/_internal/objects/integration-tests.d.ts +17 -0
- package/package.json +1 -1
|
@@ -124,6 +124,37 @@ var ChatMessageRole;
|
|
|
124
124
|
ChatMessageRole[ChatMessageRole["CHAT_MESSAGE_ROLE_ASSISTANT"] = 2] = "CHAT_MESSAGE_ROLE_ASSISTANT";
|
|
125
125
|
})(ChatMessageRole || (ChatMessageRole = {}));
|
|
126
126
|
|
|
127
|
+
// *********************************
|
|
128
|
+
// Code generated by sdkgen
|
|
129
|
+
// DO NOT EDIT!.
|
|
130
|
+
//
|
|
131
|
+
// Enums.
|
|
132
|
+
// *********************************
|
|
133
|
+
var SortDirection;
|
|
134
|
+
(function (SortDirection) {
|
|
135
|
+
SortDirection[SortDirection["SORT_DIRECTION_INVALID"] = 0] = "SORT_DIRECTION_INVALID";
|
|
136
|
+
SortDirection[SortDirection["SORT_DIRECTION_ASCENDING"] = 1] = "SORT_DIRECTION_ASCENDING";
|
|
137
|
+
SortDirection[SortDirection["SORT_DIRECTION_DESCENDING"] = 2] = "SORT_DIRECTION_DESCENDING";
|
|
138
|
+
})(SortDirection || (SortDirection = {}));
|
|
139
|
+
|
|
140
|
+
// *********************************
|
|
141
|
+
// Code generated by sdkgen
|
|
142
|
+
// DO NOT EDIT!.
|
|
143
|
+
//
|
|
144
|
+
// Enums.
|
|
145
|
+
// *********************************
|
|
146
|
+
var GenerateChatAnswerRequestModel;
|
|
147
|
+
(function (GenerateChatAnswerRequestModel) {
|
|
148
|
+
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_NOT_SET"] = 0] = "MODEL_NOT_SET";
|
|
149
|
+
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4OMNI"] = 1] = "MODEL_OPENAI_GPT_4OMNI";
|
|
150
|
+
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4OMNI_MINI"] = 2] = "MODEL_OPENAI_GPT_4OMNI_MINI";
|
|
151
|
+
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4DOT1"] = 3] = "MODEL_OPENAI_GPT_4DOT1";
|
|
152
|
+
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4DOT1_MINI"] = 4] = "MODEL_OPENAI_GPT_4DOT1_MINI";
|
|
153
|
+
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_OPENAI_GPT_4DOT1_NANO"] = 5] = "MODEL_OPENAI_GPT_4DOT1_NANO";
|
|
154
|
+
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_GOOGLE_GEMINI_2DOT5_PRO_PREVIEW"] = 6] = "MODEL_GOOGLE_GEMINI_2DOT5_PRO_PREVIEW";
|
|
155
|
+
GenerateChatAnswerRequestModel[GenerateChatAnswerRequestModel["MODEL_GOOGLE_GEMINI_2DOT5_FLASH_PREVIEW"] = 7] = "MODEL_GOOGLE_GEMINI_2DOT5_FLASH_PREVIEW";
|
|
156
|
+
})(GenerateChatAnswerRequestModel || (GenerateChatAnswerRequestModel = {}));
|
|
157
|
+
|
|
127
158
|
// *********************************
|
|
128
159
|
// Code generated by sdkgen
|
|
129
160
|
// DO NOT EDIT!.
|
|
@@ -1442,6 +1473,32 @@ function enumStringToValue$3(enumRef, value) {
|
|
|
1442
1473
|
}
|
|
1443
1474
|
return enumRef[value];
|
|
1444
1475
|
}
|
|
1476
|
+
class CancelTestRunRequest {
|
|
1477
|
+
static fromProto(proto) {
|
|
1478
|
+
let m = new CancelTestRunRequest();
|
|
1479
|
+
m = Object.assign(m, proto);
|
|
1480
|
+
if (proto.assistant) {
|
|
1481
|
+
m.assistant = AssistantKey.fromProto(proto.assistant);
|
|
1482
|
+
}
|
|
1483
|
+
return m;
|
|
1484
|
+
}
|
|
1485
|
+
constructor(kwargs) {
|
|
1486
|
+
if (!kwargs) {
|
|
1487
|
+
return;
|
|
1488
|
+
}
|
|
1489
|
+
Object.assign(this, kwargs);
|
|
1490
|
+
}
|
|
1491
|
+
toApiJson() {
|
|
1492
|
+
const toReturn = {};
|
|
1493
|
+
if (typeof this.assistant !== 'undefined' && this.assistant !== null) {
|
|
1494
|
+
toReturn['assistant'] = 'toApiJson' in this.assistant ? this.assistant.toApiJson() : this.assistant;
|
|
1495
|
+
}
|
|
1496
|
+
if (typeof this.id !== 'undefined') {
|
|
1497
|
+
toReturn['id'] = this.id;
|
|
1498
|
+
}
|
|
1499
|
+
return toReturn;
|
|
1500
|
+
}
|
|
1501
|
+
}
|
|
1445
1502
|
class DeleteTestCasesRequest {
|
|
1446
1503
|
static fromProto(proto) {
|
|
1447
1504
|
let m = new DeleteTestCasesRequest();
|
|
@@ -1527,6 +1584,9 @@ class ListTestCasesByAssistantRequest {
|
|
|
1527
1584
|
if (proto.pagingOptions) {
|
|
1528
1585
|
m.pagingOptions = PagedRequestOptions.fromProto(proto.pagingOptions);
|
|
1529
1586
|
}
|
|
1587
|
+
if (proto.sortOptions) {
|
|
1588
|
+
m.sortOptions = SortOptions.fromProto(proto.sortOptions);
|
|
1589
|
+
}
|
|
1530
1590
|
return m;
|
|
1531
1591
|
}
|
|
1532
1592
|
constructor(kwargs) {
|
|
@@ -1543,6 +1603,12 @@ class ListTestCasesByAssistantRequest {
|
|
|
1543
1603
|
if (typeof this.pagingOptions !== 'undefined' && this.pagingOptions !== null) {
|
|
1544
1604
|
toReturn['pagingOptions'] = 'toApiJson' in this.pagingOptions ? this.pagingOptions.toApiJson() : this.pagingOptions;
|
|
1545
1605
|
}
|
|
1606
|
+
if (typeof this.searchTerm !== 'undefined') {
|
|
1607
|
+
toReturn['searchTerm'] = this.searchTerm;
|
|
1608
|
+
}
|
|
1609
|
+
if (typeof this.sortOptions !== 'undefined' && this.sortOptions !== null) {
|
|
1610
|
+
toReturn['sortOptions'] = 'toApiJson' in this.sortOptions ? this.sortOptions.toApiJson() : this.sortOptions;
|
|
1611
|
+
}
|
|
1546
1612
|
return toReturn;
|
|
1547
1613
|
}
|
|
1548
1614
|
}
|
|
@@ -1679,6 +1745,32 @@ class RunTestsResponse {
|
|
|
1679
1745
|
return toReturn;
|
|
1680
1746
|
}
|
|
1681
1747
|
}
|
|
1748
|
+
class SortOptions {
|
|
1749
|
+
static fromProto(proto) {
|
|
1750
|
+
let m = new SortOptions();
|
|
1751
|
+
m = Object.assign(m, proto);
|
|
1752
|
+
if (proto.direction) {
|
|
1753
|
+
m.direction = enumStringToValue$3(SortDirection, proto.direction);
|
|
1754
|
+
}
|
|
1755
|
+
return m;
|
|
1756
|
+
}
|
|
1757
|
+
constructor(kwargs) {
|
|
1758
|
+
if (!kwargs) {
|
|
1759
|
+
return;
|
|
1760
|
+
}
|
|
1761
|
+
Object.assign(this, kwargs);
|
|
1762
|
+
}
|
|
1763
|
+
toApiJson() {
|
|
1764
|
+
const toReturn = {};
|
|
1765
|
+
if (typeof this.direction !== 'undefined') {
|
|
1766
|
+
toReturn['direction'] = this.direction;
|
|
1767
|
+
}
|
|
1768
|
+
if (typeof this.field !== 'undefined') {
|
|
1769
|
+
toReturn['field'] = this.field;
|
|
1770
|
+
}
|
|
1771
|
+
return toReturn;
|
|
1772
|
+
}
|
|
1773
|
+
}
|
|
1682
1774
|
class TestCase {
|
|
1683
1775
|
static fromProto(proto) {
|
|
1684
1776
|
let m = new TestCase();
|
|
@@ -4056,6 +4148,9 @@ class GenerateChatAnswerRequestOptions {
|
|
|
4056
4148
|
if (proto.maxTokens) {
|
|
4057
4149
|
m.maxTokens = parseInt(proto.maxTokens, 10);
|
|
4058
4150
|
}
|
|
4151
|
+
if (proto.model) {
|
|
4152
|
+
m.model = enumStringToValue(GenerateChatAnswerRequestModel, proto.model);
|
|
4153
|
+
}
|
|
4059
4154
|
return m;
|
|
4060
4155
|
}
|
|
4061
4156
|
constructor(kwargs) {
|
|
@@ -4075,6 +4170,9 @@ class GenerateChatAnswerRequestOptions {
|
|
|
4075
4170
|
if (typeof this.maxTokens !== 'undefined') {
|
|
4076
4171
|
toReturn['maxTokens'] = this.maxTokens;
|
|
4077
4172
|
}
|
|
4173
|
+
if (typeof this.model !== 'undefined') {
|
|
4174
|
+
toReturn['model'] = this.model;
|
|
4175
|
+
}
|
|
4078
4176
|
return toReturn;
|
|
4079
4177
|
}
|
|
4080
4178
|
}
|
|
@@ -4701,6 +4799,10 @@ class IntegrationTestApiService {
|
|
|
4701
4799
|
return this.http.post(this._host + "/ai_assistants.v1alpha1.IntegrationTestService/GetTestRun", request.toApiJson(), this.apiOptions())
|
|
4702
4800
|
.pipe(map(resp => GetTestRunResponse.fromProto(resp)));
|
|
4703
4801
|
}
|
|
4802
|
+
cancelTestRun(r) {
|
|
4803
|
+
const request = (r.toApiJson) ? r : new CancelTestRunRequest(r);
|
|
4804
|
+
return this.http.post(this._host + "/ai_assistants.v1alpha1.IntegrationTestService/CancelTestRun", request.toApiJson(), { ...this.apiOptions(), observe: 'response' });
|
|
4805
|
+
}
|
|
4704
4806
|
}
|
|
4705
4807
|
IntegrationTestApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: IntegrationTestApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
4706
4808
|
IntegrationTestApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: IntegrationTestApiService, providedIn: 'root' });
|
|
@@ -4878,5 +4980,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
4878
4980
|
* Generated bundle index. Do not edit.
|
|
4879
4981
|
*/
|
|
4880
4982
|
|
|
4881
|
-
export { Access, Assistant, AssistantApiService, AssistantKey, AssistantType, BuildDefaultAssistantRequest, BuildDefaultAssistantResponse, 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, 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, ListConnectionsRequest, ListConnectionsRequestFilters, ListConnectionsResponse, ListFunctionRequest, ListFunctionRequestFilters, ListFunctionResponse, ListGoalsRequest, ListGoalsRequestFilters, ListGoalsResponse, ListPromptModuleRequest, ListPromptModuleRequestFilters, ListPromptModuleResponse, ListPromptModuleVersionsRequest, ListPromptModuleVersionsResponse, ListPromptRequest, ListPromptResponse, ListPromptVersionsRequest, ListPromptVersionsResponse, ListTestCasesByAssistantRequest, ListTestCasesByAssistantResponse, ListTestRunsByAssistantRequest, ListTestRunsByAssistantResponse, ModelConfig, Namespace, NamespaceAccountGroupNamespace, NamespaceGlobalNamespace, NamespacePartnerNamespace, NamespaceSystemNamespace, OpenAIRealtimeConfig, OpenAIRealtimeConfigTurnDetection, PagedRequestOptions, PagedResponseMetadata, Prompt, PromptApiService, PromptModule, PromptModuleApiService, PromptModuleKey, PromptModuleVersion, PromptVersion, RunTestsRequest, RunTestsResponse, SetAssistantConnectionsRequest, SetAssistantConnectionsRequestConnectionState, TestCase, TestResult, TestRun, UpdateAssistantRequest, UpdateGoalRequest, UpdatePromptModuleRequest, UpdatePromptRequest, UpsertAssistantRequest, UpsertAssistantRequestOptions, UpsertAssistantResponse, UpsertConnectionRequest, UpsertFunctionRequest, UpsertGoalRequest, UpsertTestCasesRequest, VendorModel };
|
|
4983
|
+
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, GenerateChatAnswerRequestModel, GenerateChatAnswerRequestOptions, GenerateChatAnswerResponse, GetAssistantRequest, 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, ListConnectionsRequest, ListConnectionsRequestFilters, ListConnectionsResponse, ListFunctionRequest, ListFunctionRequestFilters, ListFunctionResponse, ListGoalsRequest, ListGoalsRequestFilters, ListGoalsResponse, ListPromptModuleRequest, ListPromptModuleRequestFilters, ListPromptModuleResponse, ListPromptModuleVersionsRequest, ListPromptModuleVersionsResponse, ListPromptRequest, ListPromptResponse, ListPromptVersionsRequest, ListPromptVersionsResponse, ListTestCasesByAssistantRequest, ListTestCasesByAssistantResponse, ListTestRunsByAssistantRequest, ListTestRunsByAssistantResponse, ModelConfig, 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 };
|
|
4882
4984
|
//# sourceMappingURL=vendasta-ai-assistants.mjs.map
|