@salesforce/lds-adapters-industries-nlpservice 1.266.0-dev2 → 1.266.0-dev20
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/es/es2018/industries-nlpservice.js +110 -7
- package/dist/es/es2018/types/src/generated/types/AINaturalLangProcessResultRepresentation.d.ts +5 -1
- package/dist/es/es2018/types/src/generated/types/AdditionalInformationRepresentation.d.ts +31 -0
- package/package.json +4 -4
- package/sfdc/index.js +111 -8
- package/src/raml/api.raml +31 -6
|
@@ -80,7 +80,7 @@ function createLink(ref) {
|
|
|
80
80
|
};
|
|
81
81
|
}
|
|
82
82
|
|
|
83
|
-
function validate$
|
|
83
|
+
function validate$5(obj, path = 'NullableAdditionalParametersInputMap') {
|
|
84
84
|
const v_error = (() => {
|
|
85
85
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
86
86
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -98,7 +98,7 @@ function validate$4(obj, path = 'NullableAdditionalParametersInputMap') {
|
|
|
98
98
|
return v_error === undefined ? null : v_error;
|
|
99
99
|
}
|
|
100
100
|
|
|
101
|
-
function validate$
|
|
101
|
+
function validate$4(obj, path = 'AdditionalParametersInputMap') {
|
|
102
102
|
const v_error = (() => {
|
|
103
103
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
104
104
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -106,7 +106,7 @@ function validate$3(obj, path = 'AdditionalParametersInputMap') {
|
|
|
106
106
|
if (obj.additionalParameters !== undefined) {
|
|
107
107
|
const obj_additionalParameters = obj.additionalParameters;
|
|
108
108
|
const path_additionalParameters = path + '.additionalParameters';
|
|
109
|
-
const referencepath_additionalParametersValidationError = validate$
|
|
109
|
+
const referencepath_additionalParametersValidationError = validate$5(obj_additionalParameters, path_additionalParameters);
|
|
110
110
|
if (referencepath_additionalParametersValidationError !== null) {
|
|
111
111
|
let message = 'Object doesn\'t match NullableAdditionalParametersInputMap (at "' + path_additionalParameters + '")\n';
|
|
112
112
|
message += referencepath_additionalParametersValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -117,7 +117,7 @@ function validate$3(obj, path = 'AdditionalParametersInputMap') {
|
|
|
117
117
|
return v_error === undefined ? null : v_error;
|
|
118
118
|
}
|
|
119
119
|
|
|
120
|
-
function validate$
|
|
120
|
+
function validate$3(obj, path = 'AINaturalLangProcessResultInputRepresentation') {
|
|
121
121
|
const v_error = (() => {
|
|
122
122
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
123
123
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -125,7 +125,7 @@ function validate$2(obj, path = 'AINaturalLangProcessResultInputRepresentation')
|
|
|
125
125
|
if (obj.additionalParameters !== undefined) {
|
|
126
126
|
const obj_additionalParameters = obj.additionalParameters;
|
|
127
127
|
const path_additionalParameters = path + '.additionalParameters';
|
|
128
|
-
const referencepath_additionalParametersValidationError = validate$
|
|
128
|
+
const referencepath_additionalParametersValidationError = validate$4(obj_additionalParameters, path_additionalParameters);
|
|
129
129
|
if (referencepath_additionalParametersValidationError !== null) {
|
|
130
130
|
let message = 'Object doesn\'t match AdditionalParametersInputMap (at "' + path_additionalParameters + '")\n';
|
|
131
131
|
message += referencepath_additionalParametersValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -157,13 +157,116 @@ function validate$2(obj, path = 'AINaturalLangProcessResultInputRepresentation')
|
|
|
157
157
|
return v_error === undefined ? null : v_error;
|
|
158
158
|
}
|
|
159
159
|
|
|
160
|
+
function validate$2(obj, path = 'AdditionalInformationRepresentation') {
|
|
161
|
+
const v_error = (() => {
|
|
162
|
+
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
163
|
+
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
164
|
+
}
|
|
165
|
+
if (obj.generationsResponseIds !== undefined) {
|
|
166
|
+
const obj_generationsResponseIds = obj.generationsResponseIds;
|
|
167
|
+
const path_generationsResponseIds = path + '.generationsResponseIds';
|
|
168
|
+
if (!ArrayIsArray(obj_generationsResponseIds)) {
|
|
169
|
+
return new TypeError('Expected "array" but received "' + typeof obj_generationsResponseIds + '" (at "' + path_generationsResponseIds + '")');
|
|
170
|
+
}
|
|
171
|
+
for (let i = 0; i < obj_generationsResponseIds.length; i++) {
|
|
172
|
+
const obj_generationsResponseIds_item = obj_generationsResponseIds[i];
|
|
173
|
+
const path_generationsResponseIds_item = path_generationsResponseIds + '[' + i + ']';
|
|
174
|
+
let obj_generationsResponseIds_item_union0 = null;
|
|
175
|
+
const obj_generationsResponseIds_item_union0_error = (() => {
|
|
176
|
+
if (typeof obj_generationsResponseIds_item !== 'string') {
|
|
177
|
+
return new TypeError('Expected "string" but received "' + typeof obj_generationsResponseIds_item + '" (at "' + path_generationsResponseIds_item + '")');
|
|
178
|
+
}
|
|
179
|
+
})();
|
|
180
|
+
if (obj_generationsResponseIds_item_union0_error != null) {
|
|
181
|
+
obj_generationsResponseIds_item_union0 = obj_generationsResponseIds_item_union0_error.message;
|
|
182
|
+
}
|
|
183
|
+
let obj_generationsResponseIds_item_union1 = null;
|
|
184
|
+
const obj_generationsResponseIds_item_union1_error = (() => {
|
|
185
|
+
if (obj_generationsResponseIds_item !== null) {
|
|
186
|
+
return new TypeError('Expected "null" but received "' + typeof obj_generationsResponseIds_item + '" (at "' + path_generationsResponseIds_item + '")');
|
|
187
|
+
}
|
|
188
|
+
})();
|
|
189
|
+
if (obj_generationsResponseIds_item_union1_error != null) {
|
|
190
|
+
obj_generationsResponseIds_item_union1 = obj_generationsResponseIds_item_union1_error.message;
|
|
191
|
+
}
|
|
192
|
+
if (obj_generationsResponseIds_item_union0 && obj_generationsResponseIds_item_union1) {
|
|
193
|
+
let message = 'Object doesn\'t match union (at "' + path_generationsResponseIds_item + '")';
|
|
194
|
+
message += '\n' + obj_generationsResponseIds_item_union0.split('\n').map((line) => '\t' + line).join('\n');
|
|
195
|
+
message += '\n' + obj_generationsResponseIds_item_union1.split('\n').map((line) => '\t' + line).join('\n');
|
|
196
|
+
return new TypeError(message);
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
if (obj.sessionId !== undefined) {
|
|
201
|
+
const obj_sessionId = obj.sessionId;
|
|
202
|
+
const path_sessionId = path + '.sessionId';
|
|
203
|
+
let obj_sessionId_union0 = null;
|
|
204
|
+
const obj_sessionId_union0_error = (() => {
|
|
205
|
+
if (typeof obj_sessionId !== 'string') {
|
|
206
|
+
return new TypeError('Expected "string" but received "' + typeof obj_sessionId + '" (at "' + path_sessionId + '")');
|
|
207
|
+
}
|
|
208
|
+
})();
|
|
209
|
+
if (obj_sessionId_union0_error != null) {
|
|
210
|
+
obj_sessionId_union0 = obj_sessionId_union0_error.message;
|
|
211
|
+
}
|
|
212
|
+
let obj_sessionId_union1 = null;
|
|
213
|
+
const obj_sessionId_union1_error = (() => {
|
|
214
|
+
if (obj_sessionId !== null) {
|
|
215
|
+
return new TypeError('Expected "null" but received "' + typeof obj_sessionId + '" (at "' + path_sessionId + '")');
|
|
216
|
+
}
|
|
217
|
+
})();
|
|
218
|
+
if (obj_sessionId_union1_error != null) {
|
|
219
|
+
obj_sessionId_union1 = obj_sessionId_union1_error.message;
|
|
220
|
+
}
|
|
221
|
+
if (obj_sessionId_union0 && obj_sessionId_union1) {
|
|
222
|
+
let message = 'Object doesn\'t match union (at "' + path_sessionId + '")';
|
|
223
|
+
message += '\n' + obj_sessionId_union0.split('\n').map((line) => '\t' + line).join('\n');
|
|
224
|
+
message += '\n' + obj_sessionId_union1.split('\n').map((line) => '\t' + line).join('\n');
|
|
225
|
+
return new TypeError(message);
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
})();
|
|
229
|
+
return v_error === undefined ? null : v_error;
|
|
230
|
+
}
|
|
231
|
+
|
|
160
232
|
const TTL$1 = 1000;
|
|
161
|
-
const VERSION$1 = "
|
|
233
|
+
const VERSION$1 = "daed3f78476b51a054b92fc3c9a5c931";
|
|
162
234
|
function validate$1(obj, path = 'AINaturalLangProcessResultRepresentation') {
|
|
163
235
|
const v_error = (() => {
|
|
164
236
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
165
237
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
166
238
|
}
|
|
239
|
+
if (obj.additionalInformation !== undefined) {
|
|
240
|
+
const obj_additionalInformation = obj.additionalInformation;
|
|
241
|
+
const path_additionalInformation = path + '.additionalInformation';
|
|
242
|
+
let obj_additionalInformation_union0 = null;
|
|
243
|
+
const obj_additionalInformation_union0_error = (() => {
|
|
244
|
+
const referencepath_additionalInformationValidationError = validate$2(obj_additionalInformation, path_additionalInformation);
|
|
245
|
+
if (referencepath_additionalInformationValidationError !== null) {
|
|
246
|
+
let message = 'Object doesn\'t match AdditionalInformationRepresentation (at "' + path_additionalInformation + '")\n';
|
|
247
|
+
message += referencepath_additionalInformationValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
248
|
+
return new TypeError(message);
|
|
249
|
+
}
|
|
250
|
+
})();
|
|
251
|
+
if (obj_additionalInformation_union0_error != null) {
|
|
252
|
+
obj_additionalInformation_union0 = obj_additionalInformation_union0_error.message;
|
|
253
|
+
}
|
|
254
|
+
let obj_additionalInformation_union1 = null;
|
|
255
|
+
const obj_additionalInformation_union1_error = (() => {
|
|
256
|
+
if (obj_additionalInformation !== null) {
|
|
257
|
+
return new TypeError('Expected "null" but received "' + typeof obj_additionalInformation + '" (at "' + path_additionalInformation + '")');
|
|
258
|
+
}
|
|
259
|
+
})();
|
|
260
|
+
if (obj_additionalInformation_union1_error != null) {
|
|
261
|
+
obj_additionalInformation_union1 = obj_additionalInformation_union1_error.message;
|
|
262
|
+
}
|
|
263
|
+
if (obj_additionalInformation_union0 && obj_additionalInformation_union1) {
|
|
264
|
+
let message = 'Object doesn\'t match union (at "' + path_additionalInformation + '")';
|
|
265
|
+
message += '\n' + obj_additionalInformation_union0.split('\n').map((line) => '\t' + line).join('\n');
|
|
266
|
+
message += '\n' + obj_additionalInformation_union1.split('\n').map((line) => '\t' + line).join('\n');
|
|
267
|
+
return new TypeError(message);
|
|
268
|
+
}
|
|
269
|
+
}
|
|
167
270
|
const obj_id = obj.id;
|
|
168
271
|
const path_id = path + '.id';
|
|
169
272
|
if (typeof obj_id !== 'string') {
|
|
@@ -391,7 +494,7 @@ const createResourceParams$2 = /*#__PURE__*/ createResourceParams$3(createAINatu
|
|
|
391
494
|
function typeCheckConfig$2(untrustedConfig) {
|
|
392
495
|
const config = {};
|
|
393
496
|
const untrustedConfig_aiNaturalLangProcessResultInputParam = untrustedConfig.aiNaturalLangProcessResultInputParam;
|
|
394
|
-
const referenceAINaturalLangProcessResultInputRepresentationValidationError = validate$
|
|
497
|
+
const referenceAINaturalLangProcessResultInputRepresentationValidationError = validate$3(untrustedConfig_aiNaturalLangProcessResultInputParam);
|
|
395
498
|
if (referenceAINaturalLangProcessResultInputRepresentationValidationError === null) {
|
|
396
499
|
config.aiNaturalLangProcessResultInputParam = untrustedConfig_aiNaturalLangProcessResultInputParam;
|
|
397
500
|
}
|
package/dist/es/es2018/types/src/generated/types/AINaturalLangProcessResultRepresentation.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { AdditionalInformationRepresentation as AdditionalInformationRepresentation_AdditionalInformationRepresentation } from './AdditionalInformationRepresentation';
|
|
1
2
|
import { KeyMetadata as $64$luvio_engine_KeyMetadata, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, Luvio as $64$luvio_engine_Luvio, IngestPath as $64$luvio_engine_IngestPath, Store as $64$luvio_engine_Store, BaseFragment as $64$luvio_engine_BaseFragment, ResourceIngest as $64$luvio_engine_ResourceIngest, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap } from '@luvio/engine';
|
|
2
3
|
export declare const TTL = 1000;
|
|
3
|
-
export declare const VERSION = "
|
|
4
|
+
export declare const VERSION = "daed3f78476b51a054b92fc3c9a5c931";
|
|
4
5
|
export declare function validate(obj: any, path?: string): TypeError | null;
|
|
5
6
|
export declare const RepresentationType: string;
|
|
6
7
|
export interface KeyParams extends $64$luvio_engine_KeyMetadata {
|
|
@@ -24,6 +25,8 @@ export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableSto
|
|
|
24
25
|
* serviceType (string): serviceType
|
|
25
26
|
*/
|
|
26
27
|
export interface AINaturalLangProcessResultRepresentationNormalized {
|
|
28
|
+
/** The reference record id on which the NLP operation was performed */
|
|
29
|
+
additionalInformation?: AdditionalInformationRepresentation_AdditionalInformationRepresentation | null;
|
|
27
30
|
/** The id of the AINaturalLangProcessResult record */
|
|
28
31
|
id: string;
|
|
29
32
|
/** The reference record id on which the NLP operation was performed */
|
|
@@ -46,6 +49,7 @@ export interface AINaturalLangProcessResultRepresentationNormalized {
|
|
|
46
49
|
* serviceType (string): serviceType
|
|
47
50
|
*/
|
|
48
51
|
export interface AINaturalLangProcessResultRepresentation {
|
|
52
|
+
additionalInformation?: AdditionalInformationRepresentation_AdditionalInformationRepresentation | null;
|
|
49
53
|
id: string;
|
|
50
54
|
referenceRecord: string | null;
|
|
51
55
|
requestText: string | null;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { IngestPath as $64$luvio_engine_IngestPath, Luvio as $64$luvio_engine_Luvio, Store as $64$luvio_engine_Store, FragmentSelection as $64$luvio_engine_FragmentSelection, ResourceIngest as $64$luvio_engine_ResourceIngest, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
|
|
2
|
+
export declare const VERSION = "194ed6d44881bd8f4aae960ee691bea1";
|
|
3
|
+
export declare function validate(obj: any, path?: string): TypeError | null;
|
|
4
|
+
export declare const RepresentationType: string;
|
|
5
|
+
export declare function normalize(input: AdditionalInformationRepresentation, existing: AdditionalInformationRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): AdditionalInformationRepresentationNormalized;
|
|
6
|
+
export declare const select: () => $64$luvio_engine_FragmentSelection;
|
|
7
|
+
export declare function equals(existing: AdditionalInformationRepresentationNormalized, incoming: AdditionalInformationRepresentationNormalized): boolean;
|
|
8
|
+
export declare const ingest: $64$luvio_engine_ResourceIngest;
|
|
9
|
+
export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableStoreKeyMetadataMap, luvio: $64$luvio_engine_Luvio, input: AdditionalInformationRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): void;
|
|
10
|
+
/**
|
|
11
|
+
* The output representation of the AdditionalInformation
|
|
12
|
+
*
|
|
13
|
+
* Keys:
|
|
14
|
+
* (none)
|
|
15
|
+
*/
|
|
16
|
+
export interface AdditionalInformationRepresentationNormalized {
|
|
17
|
+
/** The ids of the AINaturalLangProcessResult record */
|
|
18
|
+
generationsResponseIds?: Array<string | null>;
|
|
19
|
+
/** The session id for AINaturalLangProcessResult record processing */
|
|
20
|
+
sessionId?: string | null;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* The output representation of the AdditionalInformation
|
|
24
|
+
*
|
|
25
|
+
* Keys:
|
|
26
|
+
* (none)
|
|
27
|
+
*/
|
|
28
|
+
export interface AdditionalInformationRepresentation {
|
|
29
|
+
generationsResponseIds?: Array<string | null>;
|
|
30
|
+
sessionId?: string | null;
|
|
31
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-adapters-industries-nlpservice",
|
|
3
|
-
"version": "1.266.0-
|
|
3
|
+
"version": "1.266.0-dev20",
|
|
4
4
|
"description": "Ai Natural Language Processing Service",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"main": "dist/es/es2018/industries-nlpservice.js",
|
|
@@ -42,11 +42,11 @@
|
|
|
42
42
|
"test": "nx build:karma && karma start --single-run"
|
|
43
43
|
},
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@salesforce/lds-bindings": "^1.266.0-
|
|
45
|
+
"@salesforce/lds-bindings": "^1.266.0-dev20"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
|
-
"@salesforce/lds-compiler-plugins": "^1.266.0-
|
|
49
|
-
"@salesforce/lds-karma": "^1.266.0-
|
|
48
|
+
"@salesforce/lds-compiler-plugins": "^1.266.0-dev20",
|
|
49
|
+
"@salesforce/lds-karma": "^1.266.0-dev20"
|
|
50
50
|
},
|
|
51
51
|
"nx": {
|
|
52
52
|
"targets": {
|
package/sfdc/index.js
CHANGED
|
@@ -90,7 +90,7 @@ function createLink(ref) {
|
|
|
90
90
|
};
|
|
91
91
|
}
|
|
92
92
|
|
|
93
|
-
function validate$
|
|
93
|
+
function validate$5(obj, path = 'NullableAdditionalParametersInputMap') {
|
|
94
94
|
const v_error = (() => {
|
|
95
95
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
96
96
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -108,7 +108,7 @@ function validate$4(obj, path = 'NullableAdditionalParametersInputMap') {
|
|
|
108
108
|
return v_error === undefined ? null : v_error;
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
-
function validate$
|
|
111
|
+
function validate$4(obj, path = 'AdditionalParametersInputMap') {
|
|
112
112
|
const v_error = (() => {
|
|
113
113
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
114
114
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -116,7 +116,7 @@ function validate$3(obj, path = 'AdditionalParametersInputMap') {
|
|
|
116
116
|
if (obj.additionalParameters !== undefined) {
|
|
117
117
|
const obj_additionalParameters = obj.additionalParameters;
|
|
118
118
|
const path_additionalParameters = path + '.additionalParameters';
|
|
119
|
-
const referencepath_additionalParametersValidationError = validate$
|
|
119
|
+
const referencepath_additionalParametersValidationError = validate$5(obj_additionalParameters, path_additionalParameters);
|
|
120
120
|
if (referencepath_additionalParametersValidationError !== null) {
|
|
121
121
|
let message = 'Object doesn\'t match NullableAdditionalParametersInputMap (at "' + path_additionalParameters + '")\n';
|
|
122
122
|
message += referencepath_additionalParametersValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -127,7 +127,7 @@ function validate$3(obj, path = 'AdditionalParametersInputMap') {
|
|
|
127
127
|
return v_error === undefined ? null : v_error;
|
|
128
128
|
}
|
|
129
129
|
|
|
130
|
-
function validate$
|
|
130
|
+
function validate$3(obj, path = 'AINaturalLangProcessResultInputRepresentation') {
|
|
131
131
|
const v_error = (() => {
|
|
132
132
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
133
133
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -135,7 +135,7 @@ function validate$2(obj, path = 'AINaturalLangProcessResultInputRepresentation')
|
|
|
135
135
|
if (obj.additionalParameters !== undefined) {
|
|
136
136
|
const obj_additionalParameters = obj.additionalParameters;
|
|
137
137
|
const path_additionalParameters = path + '.additionalParameters';
|
|
138
|
-
const referencepath_additionalParametersValidationError = validate$
|
|
138
|
+
const referencepath_additionalParametersValidationError = validate$4(obj_additionalParameters, path_additionalParameters);
|
|
139
139
|
if (referencepath_additionalParametersValidationError !== null) {
|
|
140
140
|
let message = 'Object doesn\'t match AdditionalParametersInputMap (at "' + path_additionalParameters + '")\n';
|
|
141
141
|
message += referencepath_additionalParametersValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -167,13 +167,116 @@ function validate$2(obj, path = 'AINaturalLangProcessResultInputRepresentation')
|
|
|
167
167
|
return v_error === undefined ? null : v_error;
|
|
168
168
|
}
|
|
169
169
|
|
|
170
|
+
function validate$2(obj, path = 'AdditionalInformationRepresentation') {
|
|
171
|
+
const v_error = (() => {
|
|
172
|
+
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
173
|
+
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
174
|
+
}
|
|
175
|
+
if (obj.generationsResponseIds !== undefined) {
|
|
176
|
+
const obj_generationsResponseIds = obj.generationsResponseIds;
|
|
177
|
+
const path_generationsResponseIds = path + '.generationsResponseIds';
|
|
178
|
+
if (!ArrayIsArray(obj_generationsResponseIds)) {
|
|
179
|
+
return new TypeError('Expected "array" but received "' + typeof obj_generationsResponseIds + '" (at "' + path_generationsResponseIds + '")');
|
|
180
|
+
}
|
|
181
|
+
for (let i = 0; i < obj_generationsResponseIds.length; i++) {
|
|
182
|
+
const obj_generationsResponseIds_item = obj_generationsResponseIds[i];
|
|
183
|
+
const path_generationsResponseIds_item = path_generationsResponseIds + '[' + i + ']';
|
|
184
|
+
let obj_generationsResponseIds_item_union0 = null;
|
|
185
|
+
const obj_generationsResponseIds_item_union0_error = (() => {
|
|
186
|
+
if (typeof obj_generationsResponseIds_item !== 'string') {
|
|
187
|
+
return new TypeError('Expected "string" but received "' + typeof obj_generationsResponseIds_item + '" (at "' + path_generationsResponseIds_item + '")');
|
|
188
|
+
}
|
|
189
|
+
})();
|
|
190
|
+
if (obj_generationsResponseIds_item_union0_error != null) {
|
|
191
|
+
obj_generationsResponseIds_item_union0 = obj_generationsResponseIds_item_union0_error.message;
|
|
192
|
+
}
|
|
193
|
+
let obj_generationsResponseIds_item_union1 = null;
|
|
194
|
+
const obj_generationsResponseIds_item_union1_error = (() => {
|
|
195
|
+
if (obj_generationsResponseIds_item !== null) {
|
|
196
|
+
return new TypeError('Expected "null" but received "' + typeof obj_generationsResponseIds_item + '" (at "' + path_generationsResponseIds_item + '")');
|
|
197
|
+
}
|
|
198
|
+
})();
|
|
199
|
+
if (obj_generationsResponseIds_item_union1_error != null) {
|
|
200
|
+
obj_generationsResponseIds_item_union1 = obj_generationsResponseIds_item_union1_error.message;
|
|
201
|
+
}
|
|
202
|
+
if (obj_generationsResponseIds_item_union0 && obj_generationsResponseIds_item_union1) {
|
|
203
|
+
let message = 'Object doesn\'t match union (at "' + path_generationsResponseIds_item + '")';
|
|
204
|
+
message += '\n' + obj_generationsResponseIds_item_union0.split('\n').map((line) => '\t' + line).join('\n');
|
|
205
|
+
message += '\n' + obj_generationsResponseIds_item_union1.split('\n').map((line) => '\t' + line).join('\n');
|
|
206
|
+
return new TypeError(message);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
if (obj.sessionId !== undefined) {
|
|
211
|
+
const obj_sessionId = obj.sessionId;
|
|
212
|
+
const path_sessionId = path + '.sessionId';
|
|
213
|
+
let obj_sessionId_union0 = null;
|
|
214
|
+
const obj_sessionId_union0_error = (() => {
|
|
215
|
+
if (typeof obj_sessionId !== 'string') {
|
|
216
|
+
return new TypeError('Expected "string" but received "' + typeof obj_sessionId + '" (at "' + path_sessionId + '")');
|
|
217
|
+
}
|
|
218
|
+
})();
|
|
219
|
+
if (obj_sessionId_union0_error != null) {
|
|
220
|
+
obj_sessionId_union0 = obj_sessionId_union0_error.message;
|
|
221
|
+
}
|
|
222
|
+
let obj_sessionId_union1 = null;
|
|
223
|
+
const obj_sessionId_union1_error = (() => {
|
|
224
|
+
if (obj_sessionId !== null) {
|
|
225
|
+
return new TypeError('Expected "null" but received "' + typeof obj_sessionId + '" (at "' + path_sessionId + '")');
|
|
226
|
+
}
|
|
227
|
+
})();
|
|
228
|
+
if (obj_sessionId_union1_error != null) {
|
|
229
|
+
obj_sessionId_union1 = obj_sessionId_union1_error.message;
|
|
230
|
+
}
|
|
231
|
+
if (obj_sessionId_union0 && obj_sessionId_union1) {
|
|
232
|
+
let message = 'Object doesn\'t match union (at "' + path_sessionId + '")';
|
|
233
|
+
message += '\n' + obj_sessionId_union0.split('\n').map((line) => '\t' + line).join('\n');
|
|
234
|
+
message += '\n' + obj_sessionId_union1.split('\n').map((line) => '\t' + line).join('\n');
|
|
235
|
+
return new TypeError(message);
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
})();
|
|
239
|
+
return v_error === undefined ? null : v_error;
|
|
240
|
+
}
|
|
241
|
+
|
|
170
242
|
const TTL$1 = 1000;
|
|
171
|
-
const VERSION$1 = "
|
|
243
|
+
const VERSION$1 = "daed3f78476b51a054b92fc3c9a5c931";
|
|
172
244
|
function validate$1(obj, path = 'AINaturalLangProcessResultRepresentation') {
|
|
173
245
|
const v_error = (() => {
|
|
174
246
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
175
247
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
176
248
|
}
|
|
249
|
+
if (obj.additionalInformation !== undefined) {
|
|
250
|
+
const obj_additionalInformation = obj.additionalInformation;
|
|
251
|
+
const path_additionalInformation = path + '.additionalInformation';
|
|
252
|
+
let obj_additionalInformation_union0 = null;
|
|
253
|
+
const obj_additionalInformation_union0_error = (() => {
|
|
254
|
+
const referencepath_additionalInformationValidationError = validate$2(obj_additionalInformation, path_additionalInformation);
|
|
255
|
+
if (referencepath_additionalInformationValidationError !== null) {
|
|
256
|
+
let message = 'Object doesn\'t match AdditionalInformationRepresentation (at "' + path_additionalInformation + '")\n';
|
|
257
|
+
message += referencepath_additionalInformationValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
258
|
+
return new TypeError(message);
|
|
259
|
+
}
|
|
260
|
+
})();
|
|
261
|
+
if (obj_additionalInformation_union0_error != null) {
|
|
262
|
+
obj_additionalInformation_union0 = obj_additionalInformation_union0_error.message;
|
|
263
|
+
}
|
|
264
|
+
let obj_additionalInformation_union1 = null;
|
|
265
|
+
const obj_additionalInformation_union1_error = (() => {
|
|
266
|
+
if (obj_additionalInformation !== null) {
|
|
267
|
+
return new TypeError('Expected "null" but received "' + typeof obj_additionalInformation + '" (at "' + path_additionalInformation + '")');
|
|
268
|
+
}
|
|
269
|
+
})();
|
|
270
|
+
if (obj_additionalInformation_union1_error != null) {
|
|
271
|
+
obj_additionalInformation_union1 = obj_additionalInformation_union1_error.message;
|
|
272
|
+
}
|
|
273
|
+
if (obj_additionalInformation_union0 && obj_additionalInformation_union1) {
|
|
274
|
+
let message = 'Object doesn\'t match union (at "' + path_additionalInformation + '")';
|
|
275
|
+
message += '\n' + obj_additionalInformation_union0.split('\n').map((line) => '\t' + line).join('\n');
|
|
276
|
+
message += '\n' + obj_additionalInformation_union1.split('\n').map((line) => '\t' + line).join('\n');
|
|
277
|
+
return new TypeError(message);
|
|
278
|
+
}
|
|
279
|
+
}
|
|
177
280
|
const obj_id = obj.id;
|
|
178
281
|
const path_id = path + '.id';
|
|
179
282
|
if (typeof obj_id !== 'string') {
|
|
@@ -401,7 +504,7 @@ const createResourceParams$2 = /*#__PURE__*/ createResourceParams$3(createAINatu
|
|
|
401
504
|
function typeCheckConfig$2(untrustedConfig) {
|
|
402
505
|
const config = {};
|
|
403
506
|
const untrustedConfig_aiNaturalLangProcessResultInputParam = untrustedConfig.aiNaturalLangProcessResultInputParam;
|
|
404
|
-
const referenceAINaturalLangProcessResultInputRepresentationValidationError = validate$
|
|
507
|
+
const referenceAINaturalLangProcessResultInputRepresentationValidationError = validate$3(untrustedConfig_aiNaturalLangProcessResultInputParam);
|
|
405
508
|
if (referenceAINaturalLangProcessResultInputRepresentationValidationError === null) {
|
|
406
509
|
config.aiNaturalLangProcessResultInputParam = untrustedConfig_aiNaturalLangProcessResultInputParam;
|
|
407
510
|
}
|
|
@@ -838,4 +941,4 @@ withDefaultLuvio((luvio) => {
|
|
|
838
941
|
});
|
|
839
942
|
|
|
840
943
|
export { createAINaturalLangProcessResult, getAINaturalLangProcessResultsByReferenceRecordId, getAINaturalLangProcessResultsByReferenceRecordId_imperative, getAINaturalLangProcessResultsBySourceId, getAINaturalLangProcessResultsBySourceId_imperative };
|
|
841
|
-
// version: 1.266.0-
|
|
944
|
+
// version: 1.266.0-dev20-1e6923024
|
package/src/raml/api.raml
CHANGED
|
@@ -25,6 +25,20 @@ annotationTypes:
|
|
|
25
25
|
type: string
|
|
26
26
|
allowedTargets: TypeDeclaration
|
|
27
27
|
types:
|
|
28
|
+
AdditionalInformationRepresentation:
|
|
29
|
+
description: The output representation of the AdditionalInformation
|
|
30
|
+
type: object
|
|
31
|
+
properties:
|
|
32
|
+
generationsResponseIds:
|
|
33
|
+
description: The ids of the AINaturalLangProcessResult record
|
|
34
|
+
type: array
|
|
35
|
+
items:
|
|
36
|
+
type: string | nil
|
|
37
|
+
required: false
|
|
38
|
+
sessionId:
|
|
39
|
+
description: The session id for AINaturalLangProcessResult record processing
|
|
40
|
+
type: string | nil
|
|
41
|
+
required: false
|
|
28
42
|
AdditionalParametersInputMap:
|
|
29
43
|
description: Represents a map of additional parameters.
|
|
30
44
|
properties:
|
|
@@ -71,11 +85,13 @@ types:
|
|
|
71
85
|
description: Service Type
|
|
72
86
|
type: string
|
|
73
87
|
enum:
|
|
74
|
-
-
|
|
88
|
+
- Amazon_Comprehend_Entity_Extraction
|
|
75
89
|
- Amazon_Comprehend_Keyphrase_Extraction
|
|
90
|
+
- GenAI_Assessment_Questions_Extraction
|
|
91
|
+
- IndustriesFilebasedQuestionAnswer
|
|
76
92
|
- OpenAIClauseExtraction
|
|
77
93
|
- OpenAIClauseGeneration
|
|
78
|
-
-
|
|
94
|
+
- OpenAIEntityExtraction
|
|
79
95
|
- OpenAISurveyGeneration
|
|
80
96
|
- OpenAITranslation
|
|
81
97
|
required: false # TODO Hand-rolled W-9314597
|
|
@@ -87,6 +103,10 @@ types:
|
|
|
87
103
|
description: The output representation of the AINaturalLangProcessResult
|
|
88
104
|
type: object
|
|
89
105
|
properties:
|
|
106
|
+
additionalInformation:
|
|
107
|
+
description: The reference record id on which the NLP operation was performed
|
|
108
|
+
type: AdditionalInformationRepresentation | nil
|
|
109
|
+
required: false
|
|
90
110
|
id:
|
|
91
111
|
description: The id of the AINaturalLangProcessResult record
|
|
92
112
|
type: string
|
|
@@ -308,11 +328,13 @@ types:
|
|
|
308
328
|
items:
|
|
309
329
|
type: string
|
|
310
330
|
enum:
|
|
311
|
-
-
|
|
331
|
+
- Amazon_Comprehend_Entity_Extraction
|
|
312
332
|
- Amazon_Comprehend_Keyphrase_Extraction
|
|
333
|
+
- GenAI_Assessment_Questions_Extraction
|
|
334
|
+
- IndustriesFilebasedQuestionAnswer
|
|
313
335
|
- OpenAIClauseExtraction
|
|
314
336
|
- OpenAIClauseGeneration
|
|
315
|
-
-
|
|
337
|
+
- OpenAIEntityExtraction
|
|
316
338
|
- OpenAISurveyGeneration
|
|
317
339
|
- OpenAITranslation
|
|
318
340
|
(oas-collectionFormat): csv
|
|
@@ -338,12 +360,15 @@ types:
|
|
|
338
360
|
items:
|
|
339
361
|
type: string
|
|
340
362
|
enum:
|
|
341
|
-
-
|
|
363
|
+
- Amazon_Comprehend_Entity_Extraction
|
|
342
364
|
- Amazon_Comprehend_Keyphrase_Extraction
|
|
365
|
+
- GenAI_Assessment_Questions_Extraction
|
|
366
|
+
- IndustriesFilebasedQuestionAnswer
|
|
343
367
|
- OpenAIClauseExtraction
|
|
344
368
|
- OpenAIClauseGeneration
|
|
345
|
-
-
|
|
369
|
+
- OpenAIEntityExtraction
|
|
346
370
|
- OpenAISurveyGeneration
|
|
371
|
+
- OpenAITranslation
|
|
347
372
|
(oas-collectionFormat): csv
|
|
348
373
|
uriParameters:
|
|
349
374
|
sourceRecordId:
|