@salesforce/lds-adapters-service-einsteinllm 1.380.0-dev15 → 1.380.0-dev17
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/service-einsteinllm.js +1334 -884
- package/dist/es/es2018/types/src/generated/adapters/getTemplateType.d.ts +27 -0
- package/dist/es/es2018/types/src/generated/artifacts/main.d.ts +1 -0
- package/dist/es/es2018/types/src/generated/artifacts/sfdc.d.ts +3 -1
- package/dist/es/es2018/types/src/generated/resources/getEinsteinPromptTemplateTypesByTemplateTypeName.d.ts +15 -0
- package/dist/es/es2018/types/src/generated/types/EinsteinPromptTypeRecordRepresentation.d.ts +35 -0
- package/dist/es/es2018/types/src/generated/types/EinsteinPromptTypeSchemaInputFieldRepresentation.d.ts +37 -0
- package/dist/es/es2018/types/src/generated/types/EinsteinPromptTypeSchemaRepresentation.d.ts +35 -0
- package/package.json +4 -4
- package/sfdc/index.js +1288 -830
- package/src/raml/api.raml +64 -0
- package/src/raml/luvio.raml +7 -0
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* For full license text, see the LICENSE.txt file
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$
|
|
7
|
+
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$b, StoreKeyMap, createResourceParams as createResourceParams$i, typeCheckConfig as typeCheckConfig$i } from '@luvio/engine';
|
|
8
8
|
|
|
9
9
|
const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
|
|
10
10
|
const { keys: ObjectKeys$1, create: ObjectCreate$1 } = Object;
|
|
@@ -168,7 +168,7 @@ function createLink(ref) {
|
|
|
168
168
|
};
|
|
169
169
|
}
|
|
170
170
|
|
|
171
|
-
function validate$
|
|
171
|
+
function validate$E(obj, path = 'EinsteinLlmEmbeddingsAdditionalConfigInputRepresentation') {
|
|
172
172
|
const v_error = (() => {
|
|
173
173
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
174
174
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -212,7 +212,7 @@ function validate$B(obj, path = 'EinsteinLlmEmbeddingsAdditionalConfigInputRepre
|
|
|
212
212
|
return v_error === undefined ? null : v_error;
|
|
213
213
|
}
|
|
214
214
|
|
|
215
|
-
function validate$
|
|
215
|
+
function validate$D(obj, path = 'WrappedListString') {
|
|
216
216
|
const v_error = (() => {
|
|
217
217
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
218
218
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -233,14 +233,14 @@ function validate$A(obj, path = 'WrappedListString') {
|
|
|
233
233
|
return v_error === undefined ? null : v_error;
|
|
234
234
|
}
|
|
235
235
|
|
|
236
|
-
function validate$
|
|
236
|
+
function validate$C(obj, path = 'EinsteinLlmEmbeddingsInputRepresentation') {
|
|
237
237
|
const v_error = (() => {
|
|
238
238
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
239
239
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
240
240
|
}
|
|
241
241
|
const obj_additionalConfig = obj.additionalConfig;
|
|
242
242
|
const path_additionalConfig = path + '.additionalConfig';
|
|
243
|
-
const referencepath_additionalConfigValidationError = validate$
|
|
243
|
+
const referencepath_additionalConfigValidationError = validate$E(obj_additionalConfig, path_additionalConfig);
|
|
244
244
|
if (referencepath_additionalConfigValidationError !== null) {
|
|
245
245
|
let message = 'Object doesn\'t match EinsteinLlmEmbeddingsAdditionalConfigInputRepresentation (at "' + path_additionalConfig + '")\n';
|
|
246
246
|
message += referencepath_additionalConfigValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -248,7 +248,7 @@ function validate$z(obj, path = 'EinsteinLlmEmbeddingsInputRepresentation') {
|
|
|
248
248
|
}
|
|
249
249
|
const obj_prompts = obj.prompts;
|
|
250
250
|
const path_prompts = path + '.prompts';
|
|
251
|
-
const referencepath_promptsValidationError = validate$
|
|
251
|
+
const referencepath_promptsValidationError = validate$D(obj_prompts, path_prompts);
|
|
252
252
|
if (referencepath_promptsValidationError !== null) {
|
|
253
253
|
let message = 'Object doesn\'t match WrappedListString (at "' + path_prompts + '")\n';
|
|
254
254
|
message += referencepath_promptsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -265,8 +265,8 @@ function validate$z(obj, path = 'EinsteinLlmEmbeddingsInputRepresentation') {
|
|
|
265
265
|
return v_error === undefined ? null : v_error;
|
|
266
266
|
}
|
|
267
267
|
|
|
268
|
-
const VERSION$
|
|
269
|
-
function validate$
|
|
268
|
+
const VERSION$s = "5ed5ccc6fa6f15691ec0fc1080e41fe6";
|
|
269
|
+
function validate$B(obj, path = 'EinsteinLlmEmbeddingItemRepresentation') {
|
|
270
270
|
const v_error = (() => {
|
|
271
271
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
272
272
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -287,10 +287,10 @@ function validate$y(obj, path = 'EinsteinLlmEmbeddingItemRepresentation') {
|
|
|
287
287
|
})();
|
|
288
288
|
return v_error === undefined ? null : v_error;
|
|
289
289
|
}
|
|
290
|
-
const select$
|
|
290
|
+
const select$K = function EinsteinLlmEmbeddingItemRepresentationSelect() {
|
|
291
291
|
return {
|
|
292
292
|
kind: 'Fragment',
|
|
293
|
-
version: VERSION$
|
|
293
|
+
version: VERSION$s,
|
|
294
294
|
private: [],
|
|
295
295
|
selections: [
|
|
296
296
|
{
|
|
@@ -305,7 +305,7 @@ const select$G = function EinsteinLlmEmbeddingItemRepresentationSelect() {
|
|
|
305
305
|
]
|
|
306
306
|
};
|
|
307
307
|
};
|
|
308
|
-
function equals$
|
|
308
|
+
function equals$s(existing, incoming) {
|
|
309
309
|
const existing_index = existing.index;
|
|
310
310
|
const incoming_index = incoming.index;
|
|
311
311
|
if (!(existing_index === incoming_index)) {
|
|
@@ -324,9 +324,9 @@ function equals$p(existing, incoming) {
|
|
|
324
324
|
return true;
|
|
325
325
|
}
|
|
326
326
|
|
|
327
|
-
const TTL$
|
|
328
|
-
const VERSION$
|
|
329
|
-
function validate$
|
|
327
|
+
const TTL$b = 100;
|
|
328
|
+
const VERSION$r = "d9873651f09d29764ef4d4231eb653d7";
|
|
329
|
+
function validate$A(obj, path = 'EinsteinLlmEmbeddingsRepresentation') {
|
|
330
330
|
const v_error = (() => {
|
|
331
331
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
332
332
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -339,7 +339,7 @@ function validate$x(obj, path = 'EinsteinLlmEmbeddingsRepresentation') {
|
|
|
339
339
|
for (let i = 0; i < obj_embeddings.length; i++) {
|
|
340
340
|
const obj_embeddings_item = obj_embeddings[i];
|
|
341
341
|
const path_embeddings_item = path_embeddings + '[' + i + ']';
|
|
342
|
-
const referencepath_embeddings_itemValidationError = validate$
|
|
342
|
+
const referencepath_embeddings_itemValidationError = validate$B(obj_embeddings_item, path_embeddings_item);
|
|
343
343
|
if (referencepath_embeddings_itemValidationError !== null) {
|
|
344
344
|
let message = 'Object doesn\'t match EinsteinLlmEmbeddingItemRepresentation (at "' + path_embeddings_item + '")\n';
|
|
345
345
|
message += referencepath_embeddings_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -363,15 +363,15 @@ function validate$x(obj, path = 'EinsteinLlmEmbeddingsRepresentation') {
|
|
|
363
363
|
})();
|
|
364
364
|
return v_error === undefined ? null : v_error;
|
|
365
365
|
}
|
|
366
|
-
const RepresentationType$
|
|
367
|
-
function normalize$
|
|
366
|
+
const RepresentationType$b = 'EinsteinLlmEmbeddingsRepresentation';
|
|
367
|
+
function normalize$b(input, existing, path, luvio, store, timestamp) {
|
|
368
368
|
return input;
|
|
369
369
|
}
|
|
370
|
-
const select$
|
|
371
|
-
const { selections: EinsteinLlmEmbeddingItemRepresentation__selections, opaque: EinsteinLlmEmbeddingItemRepresentation__opaque, } = select$
|
|
370
|
+
const select$J = function EinsteinLlmEmbeddingsRepresentationSelect() {
|
|
371
|
+
const { selections: EinsteinLlmEmbeddingItemRepresentation__selections, opaque: EinsteinLlmEmbeddingItemRepresentation__opaque, } = select$K();
|
|
372
372
|
return {
|
|
373
373
|
kind: 'Fragment',
|
|
374
|
-
version: VERSION$
|
|
374
|
+
version: VERSION$r,
|
|
375
375
|
private: [],
|
|
376
376
|
selections: [
|
|
377
377
|
{
|
|
@@ -388,11 +388,11 @@ const select$F = function EinsteinLlmEmbeddingsRepresentationSelect() {
|
|
|
388
388
|
]
|
|
389
389
|
};
|
|
390
390
|
};
|
|
391
|
-
function equals$
|
|
391
|
+
function equals$r(existing, incoming) {
|
|
392
392
|
const existing_embeddings = existing.embeddings;
|
|
393
393
|
const incoming_embeddings = incoming.embeddings;
|
|
394
394
|
const equals_embeddings_items = equalsArray(existing_embeddings, incoming_embeddings, (existing_embeddings_item, incoming_embeddings_item) => {
|
|
395
|
-
if (!(equals$
|
|
395
|
+
if (!(equals$s(existing_embeddings_item, incoming_embeddings_item))) {
|
|
396
396
|
return false;
|
|
397
397
|
}
|
|
398
398
|
});
|
|
@@ -411,44 +411,44 @@ function equals$o(existing, incoming) {
|
|
|
411
411
|
}
|
|
412
412
|
return true;
|
|
413
413
|
}
|
|
414
|
-
const ingest$
|
|
414
|
+
const ingest$b = function EinsteinLlmEmbeddingsRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
415
415
|
if (process.env.NODE_ENV !== 'production') {
|
|
416
|
-
const validateError = validate$
|
|
416
|
+
const validateError = validate$A(input);
|
|
417
417
|
if (validateError !== null) {
|
|
418
418
|
throw validateError;
|
|
419
419
|
}
|
|
420
420
|
}
|
|
421
421
|
const key = path.fullPath;
|
|
422
|
-
const ttlToUse = TTL$
|
|
423
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
422
|
+
const ttlToUse = TTL$b;
|
|
423
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$b, "EinsteinLLM", VERSION$r, RepresentationType$b, equals$r);
|
|
424
424
|
return createLink(key);
|
|
425
425
|
};
|
|
426
|
-
function getTypeCacheKeys$
|
|
426
|
+
function getTypeCacheKeys$b(rootKeySet, luvio, input, fullPathFactory) {
|
|
427
427
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
428
428
|
const rootKey = fullPathFactory();
|
|
429
429
|
rootKeySet.set(rootKey, {
|
|
430
430
|
namespace: keyPrefix,
|
|
431
|
-
representationName: RepresentationType$
|
|
431
|
+
representationName: RepresentationType$b,
|
|
432
432
|
mergeable: false
|
|
433
433
|
});
|
|
434
434
|
}
|
|
435
435
|
|
|
436
|
-
function select$
|
|
437
|
-
return select$
|
|
436
|
+
function select$I(luvio, params) {
|
|
437
|
+
return select$J();
|
|
438
438
|
}
|
|
439
|
-
function keyBuilder$
|
|
439
|
+
function keyBuilder$p(luvio, params) {
|
|
440
440
|
return keyPrefix + '::EinsteinLlmEmbeddingsRepresentation:(' + stableJSONStringify(params.body.embeddingsInput.additionalConfig.additionalParameters) + '::' + 'embeddingsInput.additionalConfig.applicationName:' + params.body.embeddingsInput.additionalConfig.applicationName + '::' + (params.body.embeddingsInput.additionalConfig.enablePiiMasking === undefined ? 'embeddingsInput.additionalConfig.enablePiiMasking' : 'embeddingsInput.additionalConfig.enablePiiMasking:' + params.body.embeddingsInput.additionalConfig.enablePiiMasking) + '::' + (params.body.embeddingsInput.additionalConfig.model === undefined ? 'embeddingsInput.additionalConfig.model' : 'embeddingsInput.additionalConfig.model:' + params.body.embeddingsInput.additionalConfig.model) + '::' + 'embeddingsInput.prompts.wrappedListString:' + params.body.embeddingsInput.prompts.wrappedListString + '::' + (params.body.embeddingsInput.provider === undefined ? 'embeddingsInput.provider' : 'embeddingsInput.provider:' + params.body.embeddingsInput.provider) + ')';
|
|
441
441
|
}
|
|
442
|
-
function getResponseCacheKeys$
|
|
443
|
-
getTypeCacheKeys$
|
|
442
|
+
function getResponseCacheKeys$h(storeKeyMap, luvio, resourceParams, response) {
|
|
443
|
+
getTypeCacheKeys$b(storeKeyMap, luvio, response, () => keyBuilder$p(luvio, resourceParams));
|
|
444
444
|
}
|
|
445
|
-
function ingestSuccess$
|
|
445
|
+
function ingestSuccess$h(luvio, resourceParams, response, snapshotRefresh) {
|
|
446
446
|
const { body } = response;
|
|
447
|
-
const key = keyBuilder$
|
|
448
|
-
luvio.storeIngest(key, ingest$
|
|
447
|
+
const key = keyBuilder$p(luvio, resourceParams);
|
|
448
|
+
luvio.storeIngest(key, ingest$b, body);
|
|
449
449
|
const snapshot = luvio.storeLookup({
|
|
450
450
|
recordId: key,
|
|
451
|
-
node: select$
|
|
451
|
+
node: select$I(),
|
|
452
452
|
variables: {},
|
|
453
453
|
}, snapshotRefresh);
|
|
454
454
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -459,19 +459,19 @@ function ingestSuccess$g(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
459
459
|
deepFreeze(snapshot.data);
|
|
460
460
|
return snapshot;
|
|
461
461
|
}
|
|
462
|
-
function ingestError$
|
|
463
|
-
const key = keyBuilder$
|
|
462
|
+
function ingestError$a(luvio, params, error, snapshotRefresh) {
|
|
463
|
+
const key = keyBuilder$p(luvio, params);
|
|
464
464
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
465
465
|
const storeMetadataParams = {
|
|
466
|
-
ttl: TTL$
|
|
466
|
+
ttl: TTL$b,
|
|
467
467
|
namespace: keyPrefix,
|
|
468
|
-
version: VERSION$
|
|
469
|
-
representationName: RepresentationType$
|
|
468
|
+
version: VERSION$r,
|
|
469
|
+
representationName: RepresentationType$b
|
|
470
470
|
};
|
|
471
471
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
472
472
|
return errorSnapshot;
|
|
473
473
|
}
|
|
474
|
-
function createResourceRequest$
|
|
474
|
+
function createResourceRequest$h(config) {
|
|
475
475
|
const headers = {};
|
|
476
476
|
return {
|
|
477
477
|
baseUri: '/services/data/v65.0',
|
|
@@ -485,97 +485,97 @@ function createResourceRequest$g(config) {
|
|
|
485
485
|
};
|
|
486
486
|
}
|
|
487
487
|
|
|
488
|
-
const adapterName$
|
|
488
|
+
const adapterName$h = 'createEmbeddings';
|
|
489
489
|
const createEmbeddings_ConfigPropertyMetadata = [
|
|
490
490
|
generateParamConfigMetadata('embeddingsInput', true, 2 /* Body */, 4 /* Unsupported */),
|
|
491
491
|
];
|
|
492
|
-
const createEmbeddings_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
493
|
-
const createResourceParams$
|
|
494
|
-
function keyBuilder$
|
|
495
|
-
const resourceParams = createResourceParams$
|
|
496
|
-
return keyBuilder$
|
|
492
|
+
const createEmbeddings_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$h, createEmbeddings_ConfigPropertyMetadata);
|
|
493
|
+
const createResourceParams$h = /*#__PURE__*/ createResourceParams$i(createEmbeddings_ConfigPropertyMetadata);
|
|
494
|
+
function keyBuilder$o(luvio, config) {
|
|
495
|
+
const resourceParams = createResourceParams$h(config);
|
|
496
|
+
return keyBuilder$p(luvio, resourceParams);
|
|
497
497
|
}
|
|
498
|
-
function typeCheckConfig$
|
|
498
|
+
function typeCheckConfig$h(untrustedConfig) {
|
|
499
499
|
const config = {};
|
|
500
500
|
const untrustedConfig_embeddingsInput = untrustedConfig.embeddingsInput;
|
|
501
|
-
const referenceEinsteinLlmEmbeddingsInputRepresentationValidationError = validate$
|
|
501
|
+
const referenceEinsteinLlmEmbeddingsInputRepresentationValidationError = validate$C(untrustedConfig_embeddingsInput);
|
|
502
502
|
if (referenceEinsteinLlmEmbeddingsInputRepresentationValidationError === null) {
|
|
503
503
|
config.embeddingsInput = untrustedConfig_embeddingsInput;
|
|
504
504
|
}
|
|
505
505
|
return config;
|
|
506
506
|
}
|
|
507
|
-
function validateAdapterConfig$
|
|
507
|
+
function validateAdapterConfig$h(untrustedConfig, configPropertyNames) {
|
|
508
508
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
509
509
|
return null;
|
|
510
510
|
}
|
|
511
511
|
if (process.env.NODE_ENV !== 'production') {
|
|
512
512
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
513
513
|
}
|
|
514
|
-
const config = typeCheckConfig$
|
|
514
|
+
const config = typeCheckConfig$h(untrustedConfig);
|
|
515
515
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
516
516
|
return null;
|
|
517
517
|
}
|
|
518
518
|
return config;
|
|
519
519
|
}
|
|
520
|
-
function adapterFragment$
|
|
521
|
-
createResourceParams$
|
|
522
|
-
return select$
|
|
520
|
+
function adapterFragment$a(luvio, config) {
|
|
521
|
+
createResourceParams$h(config);
|
|
522
|
+
return select$I();
|
|
523
523
|
}
|
|
524
|
-
function onFetchResponseSuccess$
|
|
525
|
-
const snapshot = ingestSuccess$
|
|
524
|
+
function onFetchResponseSuccess$a(luvio, config, resourceParams, response) {
|
|
525
|
+
const snapshot = ingestSuccess$h(luvio, resourceParams, response, {
|
|
526
526
|
config,
|
|
527
|
-
resolve: () => buildNetworkSnapshot$
|
|
527
|
+
resolve: () => buildNetworkSnapshot$h(luvio, config, snapshotRefreshOptions)
|
|
528
528
|
});
|
|
529
529
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
530
530
|
}
|
|
531
|
-
function onFetchResponseError$
|
|
532
|
-
const snapshot = ingestError$
|
|
531
|
+
function onFetchResponseError$a(luvio, config, resourceParams, response) {
|
|
532
|
+
const snapshot = ingestError$a(luvio, resourceParams, response, {
|
|
533
533
|
config,
|
|
534
|
-
resolve: () => buildNetworkSnapshot$
|
|
534
|
+
resolve: () => buildNetworkSnapshot$h(luvio, config, snapshotRefreshOptions)
|
|
535
535
|
});
|
|
536
536
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
537
537
|
}
|
|
538
|
-
function buildNetworkSnapshot$
|
|
539
|
-
const resourceParams = createResourceParams$
|
|
540
|
-
const request = createResourceRequest$
|
|
538
|
+
function buildNetworkSnapshot$h(luvio, config, options) {
|
|
539
|
+
const resourceParams = createResourceParams$h(config);
|
|
540
|
+
const request = createResourceRequest$h(resourceParams);
|
|
541
541
|
return luvio.dispatchResourceRequest(request, options)
|
|
542
542
|
.then((response) => {
|
|
543
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
543
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$a(luvio, config, resourceParams, response), () => {
|
|
544
544
|
const cache = new StoreKeyMap();
|
|
545
|
-
getResponseCacheKeys$
|
|
545
|
+
getResponseCacheKeys$h(cache, luvio, resourceParams, response.body);
|
|
546
546
|
return cache;
|
|
547
547
|
});
|
|
548
548
|
}, (response) => {
|
|
549
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
549
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$a(luvio, config, resourceParams, response));
|
|
550
550
|
});
|
|
551
551
|
}
|
|
552
|
-
function buildNetworkSnapshotCachePolicy$
|
|
553
|
-
return buildNetworkSnapshotCachePolicy$
|
|
552
|
+
function buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext) {
|
|
553
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$h, 'get', false);
|
|
554
554
|
}
|
|
555
|
-
function buildCachedSnapshotCachePolicy$
|
|
555
|
+
function buildCachedSnapshotCachePolicy$a(context, storeLookup) {
|
|
556
556
|
const { luvio, config } = context;
|
|
557
557
|
const selector = {
|
|
558
|
-
recordId: keyBuilder$
|
|
559
|
-
node: adapterFragment$
|
|
558
|
+
recordId: keyBuilder$o(luvio, config),
|
|
559
|
+
node: adapterFragment$a(luvio, config),
|
|
560
560
|
variables: {},
|
|
561
561
|
};
|
|
562
562
|
const cacheSnapshot = storeLookup(selector, {
|
|
563
563
|
config,
|
|
564
|
-
resolve: () => buildNetworkSnapshot$
|
|
564
|
+
resolve: () => buildNetworkSnapshot$h(luvio, config, snapshotRefreshOptions)
|
|
565
565
|
});
|
|
566
566
|
return cacheSnapshot;
|
|
567
567
|
}
|
|
568
568
|
const createEmbeddingsAdapterFactory = (luvio) => function EinsteinLLM__createEmbeddings(untrustedConfig, requestContext) {
|
|
569
|
-
const config = validateAdapterConfig$
|
|
569
|
+
const config = validateAdapterConfig$h(untrustedConfig, createEmbeddings_ConfigPropertyNames);
|
|
570
570
|
// Invalid or incomplete config
|
|
571
571
|
if (config === null) {
|
|
572
572
|
return null;
|
|
573
573
|
}
|
|
574
574
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
575
|
-
buildCachedSnapshotCachePolicy$
|
|
575
|
+
buildCachedSnapshotCachePolicy$a, buildNetworkSnapshotCachePolicy$a);
|
|
576
576
|
};
|
|
577
577
|
|
|
578
|
-
function validate$
|
|
578
|
+
function validate$z(obj, path = 'EinsteinLlmFeedbackInputRepresentation') {
|
|
579
579
|
const v_error = (() => {
|
|
580
580
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
581
581
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -622,9 +622,9 @@ function validate$w(obj, path = 'EinsteinLlmFeedbackInputRepresentation') {
|
|
|
622
622
|
return v_error === undefined ? null : v_error;
|
|
623
623
|
}
|
|
624
624
|
|
|
625
|
-
const TTL$
|
|
626
|
-
const VERSION$
|
|
627
|
-
function validate$
|
|
625
|
+
const TTL$a = 100;
|
|
626
|
+
const VERSION$q = "4033328f65865dd5d80c68a7573a4522";
|
|
627
|
+
function validate$y(obj, path = 'EinsteinLlmFeedbackRepresentation') {
|
|
628
628
|
const v_error = (() => {
|
|
629
629
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
630
630
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -637,23 +637,23 @@ function validate$v(obj, path = 'EinsteinLlmFeedbackRepresentation') {
|
|
|
637
637
|
})();
|
|
638
638
|
return v_error === undefined ? null : v_error;
|
|
639
639
|
}
|
|
640
|
-
const RepresentationType$
|
|
641
|
-
function keyBuilder$
|
|
642
|
-
return keyPrefix + '::' + RepresentationType$
|
|
640
|
+
const RepresentationType$a = 'EinsteinLlmFeedbackRepresentation';
|
|
641
|
+
function keyBuilder$n(luvio, config) {
|
|
642
|
+
return keyPrefix + '::' + RepresentationType$a + ':' + config.message;
|
|
643
643
|
}
|
|
644
644
|
function keyBuilderFromType$3(luvio, object) {
|
|
645
645
|
const keyParams = {
|
|
646
646
|
message: object.message
|
|
647
647
|
};
|
|
648
|
-
return keyBuilder$
|
|
648
|
+
return keyBuilder$n(luvio, keyParams);
|
|
649
649
|
}
|
|
650
|
-
function normalize$
|
|
650
|
+
function normalize$a(input, existing, path, luvio, store, timestamp) {
|
|
651
651
|
return input;
|
|
652
652
|
}
|
|
653
|
-
const select$
|
|
653
|
+
const select$H = function EinsteinLlmFeedbackRepresentationSelect() {
|
|
654
654
|
return {
|
|
655
655
|
kind: 'Fragment',
|
|
656
|
-
version: VERSION$
|
|
656
|
+
version: VERSION$q,
|
|
657
657
|
private: [],
|
|
658
658
|
selections: [
|
|
659
659
|
{
|
|
@@ -663,7 +663,7 @@ const select$D = function EinsteinLlmFeedbackRepresentationSelect() {
|
|
|
663
663
|
]
|
|
664
664
|
};
|
|
665
665
|
};
|
|
666
|
-
function equals$
|
|
666
|
+
function equals$q(existing, incoming) {
|
|
667
667
|
const existing_message = existing.message;
|
|
668
668
|
const incoming_message = incoming.message;
|
|
669
669
|
if (!(existing_message === incoming_message)) {
|
|
@@ -671,41 +671,41 @@ function equals$n(existing, incoming) {
|
|
|
671
671
|
}
|
|
672
672
|
return true;
|
|
673
673
|
}
|
|
674
|
-
const ingest$
|
|
674
|
+
const ingest$a = function EinsteinLlmFeedbackRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
675
675
|
if (process.env.NODE_ENV !== 'production') {
|
|
676
|
-
const validateError = validate$
|
|
676
|
+
const validateError = validate$y(input);
|
|
677
677
|
if (validateError !== null) {
|
|
678
678
|
throw validateError;
|
|
679
679
|
}
|
|
680
680
|
}
|
|
681
681
|
const key = keyBuilderFromType$3(luvio, input);
|
|
682
|
-
const ttlToUse = TTL$
|
|
683
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
682
|
+
const ttlToUse = TTL$a;
|
|
683
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$a, "EinsteinLLM", VERSION$q, RepresentationType$a, equals$q);
|
|
684
684
|
return createLink(key);
|
|
685
685
|
};
|
|
686
|
-
function getTypeCacheKeys$
|
|
686
|
+
function getTypeCacheKeys$a(rootKeySet, luvio, input, fullPathFactory) {
|
|
687
687
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
688
688
|
const rootKey = keyBuilderFromType$3(luvio, input);
|
|
689
689
|
rootKeySet.set(rootKey, {
|
|
690
690
|
namespace: keyPrefix,
|
|
691
|
-
representationName: RepresentationType$
|
|
691
|
+
representationName: RepresentationType$a,
|
|
692
692
|
mergeable: false
|
|
693
693
|
});
|
|
694
694
|
}
|
|
695
695
|
|
|
696
|
-
function select$
|
|
697
|
-
return select$
|
|
696
|
+
function select$G(luvio, params) {
|
|
697
|
+
return select$H();
|
|
698
698
|
}
|
|
699
|
-
function getResponseCacheKeys$
|
|
700
|
-
getTypeCacheKeys$
|
|
699
|
+
function getResponseCacheKeys$g(storeKeyMap, luvio, resourceParams, response) {
|
|
700
|
+
getTypeCacheKeys$a(storeKeyMap, luvio, response);
|
|
701
701
|
}
|
|
702
|
-
function ingestSuccess$
|
|
702
|
+
function ingestSuccess$g(luvio, resourceParams, response) {
|
|
703
703
|
const { body } = response;
|
|
704
704
|
const key = keyBuilderFromType$3(luvio, body);
|
|
705
|
-
luvio.storeIngest(key, ingest$
|
|
705
|
+
luvio.storeIngest(key, ingest$a, body);
|
|
706
706
|
const snapshot = luvio.storeLookup({
|
|
707
707
|
recordId: key,
|
|
708
|
-
node: select$
|
|
708
|
+
node: select$G(),
|
|
709
709
|
variables: {},
|
|
710
710
|
});
|
|
711
711
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -716,7 +716,7 @@ function ingestSuccess$f(luvio, resourceParams, response) {
|
|
|
716
716
|
deepFreeze(snapshot.data);
|
|
717
717
|
return snapshot;
|
|
718
718
|
}
|
|
719
|
-
function createResourceRequest$
|
|
719
|
+
function createResourceRequest$g(config) {
|
|
720
720
|
const headers = {};
|
|
721
721
|
return {
|
|
722
722
|
baseUri: '/services/data/v65.0',
|
|
@@ -730,45 +730,45 @@ function createResourceRequest$f(config) {
|
|
|
730
730
|
};
|
|
731
731
|
}
|
|
732
732
|
|
|
733
|
-
const adapterName$
|
|
733
|
+
const adapterName$g = 'createFeedback';
|
|
734
734
|
const createFeedback_ConfigPropertyMetadata = [
|
|
735
735
|
generateParamConfigMetadata('feedbackInput', true, 2 /* Body */, 4 /* Unsupported */),
|
|
736
736
|
];
|
|
737
|
-
const createFeedback_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
738
|
-
const createResourceParams$
|
|
739
|
-
function typeCheckConfig$
|
|
737
|
+
const createFeedback_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$g, createFeedback_ConfigPropertyMetadata);
|
|
738
|
+
const createResourceParams$g = /*#__PURE__*/ createResourceParams$i(createFeedback_ConfigPropertyMetadata);
|
|
739
|
+
function typeCheckConfig$g(untrustedConfig) {
|
|
740
740
|
const config = {};
|
|
741
741
|
const untrustedConfig_feedbackInput = untrustedConfig.feedbackInput;
|
|
742
|
-
const referenceEinsteinLlmFeedbackInputRepresentationValidationError = validate$
|
|
742
|
+
const referenceEinsteinLlmFeedbackInputRepresentationValidationError = validate$z(untrustedConfig_feedbackInput);
|
|
743
743
|
if (referenceEinsteinLlmFeedbackInputRepresentationValidationError === null) {
|
|
744
744
|
config.feedbackInput = untrustedConfig_feedbackInput;
|
|
745
745
|
}
|
|
746
746
|
return config;
|
|
747
747
|
}
|
|
748
|
-
function validateAdapterConfig$
|
|
748
|
+
function validateAdapterConfig$g(untrustedConfig, configPropertyNames) {
|
|
749
749
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
750
750
|
return null;
|
|
751
751
|
}
|
|
752
752
|
if (process.env.NODE_ENV !== 'production') {
|
|
753
753
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
754
754
|
}
|
|
755
|
-
const config = typeCheckConfig$
|
|
755
|
+
const config = typeCheckConfig$g(untrustedConfig);
|
|
756
756
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
757
757
|
return null;
|
|
758
758
|
}
|
|
759
759
|
return config;
|
|
760
760
|
}
|
|
761
|
-
function buildNetworkSnapshot$
|
|
762
|
-
const resourceParams = createResourceParams$
|
|
763
|
-
const request = createResourceRequest$
|
|
761
|
+
function buildNetworkSnapshot$g(luvio, config, options) {
|
|
762
|
+
const resourceParams = createResourceParams$g(config);
|
|
763
|
+
const request = createResourceRequest$g(resourceParams);
|
|
764
764
|
return luvio.dispatchResourceRequest(request, options)
|
|
765
765
|
.then((response) => {
|
|
766
766
|
return luvio.handleSuccessResponse(() => {
|
|
767
|
-
const snapshot = ingestSuccess$
|
|
767
|
+
const snapshot = ingestSuccess$g(luvio, resourceParams, response);
|
|
768
768
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
769
769
|
}, () => {
|
|
770
770
|
const cache = new StoreKeyMap();
|
|
771
|
-
getResponseCacheKeys$
|
|
771
|
+
getResponseCacheKeys$g(cache, luvio, resourceParams, response.body);
|
|
772
772
|
return cache;
|
|
773
773
|
});
|
|
774
774
|
}, (response) => {
|
|
@@ -778,16 +778,16 @@ function buildNetworkSnapshot$f(luvio, config, options) {
|
|
|
778
778
|
}
|
|
779
779
|
const createFeedbackAdapterFactory = (luvio) => {
|
|
780
780
|
return function createFeedback(untrustedConfig) {
|
|
781
|
-
const config = validateAdapterConfig$
|
|
781
|
+
const config = validateAdapterConfig$g(untrustedConfig, createFeedback_ConfigPropertyNames);
|
|
782
782
|
// Invalid or incomplete config
|
|
783
783
|
if (config === null) {
|
|
784
784
|
throw new Error('Invalid config for "createFeedback"');
|
|
785
785
|
}
|
|
786
|
-
return buildNetworkSnapshot$
|
|
786
|
+
return buildNetworkSnapshot$g(luvio, config);
|
|
787
787
|
};
|
|
788
788
|
};
|
|
789
789
|
|
|
790
|
-
function validate$
|
|
790
|
+
function validate$x(obj, path = 'EinsteinLlmAdditionalConfigInputRepresentation') {
|
|
791
791
|
const v_error = (() => {
|
|
792
792
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
793
793
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -870,7 +870,7 @@ function validate$u(obj, path = 'EinsteinLlmAdditionalConfigInputRepresentation'
|
|
|
870
870
|
return v_error === undefined ? null : v_error;
|
|
871
871
|
}
|
|
872
872
|
|
|
873
|
-
function validate$
|
|
873
|
+
function validate$w(obj, path = 'EinsteinLlmGenerationsInputRepresentation') {
|
|
874
874
|
const v_error = (() => {
|
|
875
875
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
876
876
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -878,7 +878,7 @@ function validate$t(obj, path = 'EinsteinLlmGenerationsInputRepresentation') {
|
|
|
878
878
|
if (obj.additionalConfig !== undefined) {
|
|
879
879
|
const obj_additionalConfig = obj.additionalConfig;
|
|
880
880
|
const path_additionalConfig = path + '.additionalConfig';
|
|
881
|
-
const referencepath_additionalConfigValidationError = validate$
|
|
881
|
+
const referencepath_additionalConfigValidationError = validate$x(obj_additionalConfig, path_additionalConfig);
|
|
882
882
|
if (referencepath_additionalConfigValidationError !== null) {
|
|
883
883
|
let message = 'Object doesn\'t match EinsteinLlmAdditionalConfigInputRepresentation (at "' + path_additionalConfig + '")\n';
|
|
884
884
|
message += referencepath_additionalConfigValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -901,8 +901,8 @@ function validate$t(obj, path = 'EinsteinLlmGenerationsInputRepresentation') {
|
|
|
901
901
|
return v_error === undefined ? null : v_error;
|
|
902
902
|
}
|
|
903
903
|
|
|
904
|
-
const VERSION$
|
|
905
|
-
function validate$
|
|
904
|
+
const VERSION$p = "9ebac74e6f964c363d5fd1913df363af";
|
|
905
|
+
function validate$v(obj, path = 'EinsteinLlmGenerationsContentQualityRepresentation') {
|
|
906
906
|
const v_error = (() => {
|
|
907
907
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
908
908
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -938,10 +938,10 @@ function validate$s(obj, path = 'EinsteinLlmGenerationsContentQualityRepresentat
|
|
|
938
938
|
})();
|
|
939
939
|
return v_error === undefined ? null : v_error;
|
|
940
940
|
}
|
|
941
|
-
const select$
|
|
941
|
+
const select$F = function EinsteinLlmGenerationsContentQualityRepresentationSelect() {
|
|
942
942
|
return {
|
|
943
943
|
kind: 'Fragment',
|
|
944
|
-
version: VERSION$
|
|
944
|
+
version: VERSION$p,
|
|
945
945
|
private: [],
|
|
946
946
|
selections: [
|
|
947
947
|
{
|
|
@@ -952,7 +952,7 @@ const select$B = function EinsteinLlmGenerationsContentQualityRepresentationSele
|
|
|
952
952
|
]
|
|
953
953
|
};
|
|
954
954
|
};
|
|
955
|
-
function equals$
|
|
955
|
+
function equals$p(existing, incoming) {
|
|
956
956
|
const existing_isToxicityDetected = existing.isToxicityDetected;
|
|
957
957
|
const incoming_isToxicityDetected = incoming.isToxicityDetected;
|
|
958
958
|
// if at least one of these optionals is defined
|
|
@@ -969,8 +969,8 @@ function equals$m(existing, incoming) {
|
|
|
969
969
|
return true;
|
|
970
970
|
}
|
|
971
971
|
|
|
972
|
-
const VERSION$
|
|
973
|
-
function validate$
|
|
972
|
+
const VERSION$o = "77af44a252cb5b45b4d9a8101368d2aa";
|
|
973
|
+
function validate$u(obj, path = 'EinsteinLlmGenerationsSafetyScoreRepresentation') {
|
|
974
974
|
const v_error = (() => {
|
|
975
975
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
976
976
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -1174,10 +1174,10 @@ function validate$r(obj, path = 'EinsteinLlmGenerationsSafetyScoreRepresentation
|
|
|
1174
1174
|
})();
|
|
1175
1175
|
return v_error === undefined ? null : v_error;
|
|
1176
1176
|
}
|
|
1177
|
-
const select$
|
|
1177
|
+
const select$E = function EinsteinLlmGenerationsSafetyScoreRepresentationSelect() {
|
|
1178
1178
|
return {
|
|
1179
1179
|
kind: 'Fragment',
|
|
1180
|
-
version: VERSION$
|
|
1180
|
+
version: VERSION$o,
|
|
1181
1181
|
private: [],
|
|
1182
1182
|
selections: [
|
|
1183
1183
|
{
|
|
@@ -1218,7 +1218,7 @@ const select$A = function EinsteinLlmGenerationsSafetyScoreRepresentationSelect(
|
|
|
1218
1218
|
]
|
|
1219
1219
|
};
|
|
1220
1220
|
};
|
|
1221
|
-
function equals$
|
|
1221
|
+
function equals$o(existing, incoming) {
|
|
1222
1222
|
const existing_hateScore = existing.hateScore;
|
|
1223
1223
|
const incoming_hateScore = incoming.hateScore;
|
|
1224
1224
|
// if at least one of these optionals is defined
|
|
@@ -1313,8 +1313,8 @@ function equals$l(existing, incoming) {
|
|
|
1313
1313
|
return true;
|
|
1314
1314
|
}
|
|
1315
1315
|
|
|
1316
|
-
const VERSION$
|
|
1317
|
-
function validate$
|
|
1316
|
+
const VERSION$n = "4a07778ff6c595d91c575188146647a1";
|
|
1317
|
+
function validate$t(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
|
|
1318
1318
|
const v_error = (() => {
|
|
1319
1319
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
1320
1320
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -1324,7 +1324,7 @@ function validate$q(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
|
|
|
1324
1324
|
const path_contentQualityRepresentation = path + '.contentQualityRepresentation';
|
|
1325
1325
|
let obj_contentQualityRepresentation_union0 = null;
|
|
1326
1326
|
const obj_contentQualityRepresentation_union0_error = (() => {
|
|
1327
|
-
const referencepath_contentQualityRepresentationValidationError = validate$
|
|
1327
|
+
const referencepath_contentQualityRepresentationValidationError = validate$v(obj_contentQualityRepresentation, path_contentQualityRepresentation);
|
|
1328
1328
|
if (referencepath_contentQualityRepresentationValidationError !== null) {
|
|
1329
1329
|
let message = 'Object doesn\'t match EinsteinLlmGenerationsContentQualityRepresentation (at "' + path_contentQualityRepresentation + '")\n';
|
|
1330
1330
|
message += referencepath_contentQualityRepresentationValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -1372,7 +1372,7 @@ function validate$q(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
|
|
|
1372
1372
|
const path_safetyScoreRepresentation = path + '.safetyScoreRepresentation';
|
|
1373
1373
|
let obj_safetyScoreRepresentation_union0 = null;
|
|
1374
1374
|
const obj_safetyScoreRepresentation_union0_error = (() => {
|
|
1375
|
-
const referencepath_safetyScoreRepresentationValidationError = validate$
|
|
1375
|
+
const referencepath_safetyScoreRepresentationValidationError = validate$u(obj_safetyScoreRepresentation, path_safetyScoreRepresentation);
|
|
1376
1376
|
if (referencepath_safetyScoreRepresentationValidationError !== null) {
|
|
1377
1377
|
let message = 'Object doesn\'t match EinsteinLlmGenerationsSafetyScoreRepresentation (at "' + path_safetyScoreRepresentation + '")\n';
|
|
1378
1378
|
message += referencepath_safetyScoreRepresentationValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -1406,12 +1406,12 @@ function validate$q(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
|
|
|
1406
1406
|
})();
|
|
1407
1407
|
return v_error === undefined ? null : v_error;
|
|
1408
1408
|
}
|
|
1409
|
-
const select$
|
|
1410
|
-
const { selections: EinsteinLlmGenerationsContentQualityRepresentation__selections, opaque: EinsteinLlmGenerationsContentQualityRepresentation__opaque, } = select$
|
|
1411
|
-
const { selections: EinsteinLlmGenerationsSafetyScoreRepresentation__selections, opaque: EinsteinLlmGenerationsSafetyScoreRepresentation__opaque, } = select$
|
|
1409
|
+
const select$D = function EinsteinLlmGenerationItemRepresentationSelect() {
|
|
1410
|
+
const { selections: EinsteinLlmGenerationsContentQualityRepresentation__selections, opaque: EinsteinLlmGenerationsContentQualityRepresentation__opaque, } = select$F();
|
|
1411
|
+
const { selections: EinsteinLlmGenerationsSafetyScoreRepresentation__selections, opaque: EinsteinLlmGenerationsSafetyScoreRepresentation__opaque, } = select$E();
|
|
1412
1412
|
return {
|
|
1413
1413
|
kind: 'Fragment',
|
|
1414
|
-
version: VERSION$
|
|
1414
|
+
version: VERSION$n,
|
|
1415
1415
|
private: [],
|
|
1416
1416
|
selections: [
|
|
1417
1417
|
{
|
|
@@ -1448,7 +1448,7 @@ const select$z = function EinsteinLlmGenerationItemRepresentationSelect() {
|
|
|
1448
1448
|
]
|
|
1449
1449
|
};
|
|
1450
1450
|
};
|
|
1451
|
-
function equals$
|
|
1451
|
+
function equals$n(existing, incoming) {
|
|
1452
1452
|
const existing_isSummarized = existing.isSummarized;
|
|
1453
1453
|
const incoming_isSummarized = incoming.isSummarized;
|
|
1454
1454
|
// if at least one of these optionals is defined
|
|
@@ -1489,7 +1489,7 @@ function equals$k(existing, incoming) {
|
|
|
1489
1489
|
if (!(existing_contentQualityRepresentation === incoming_contentQualityRepresentation
|
|
1490
1490
|
|| (existing_contentQualityRepresentation != null &&
|
|
1491
1491
|
incoming_contentQualityRepresentation != null &&
|
|
1492
|
-
equals$
|
|
1492
|
+
equals$p(existing_contentQualityRepresentation, incoming_contentQualityRepresentation)))) {
|
|
1493
1493
|
return false;
|
|
1494
1494
|
}
|
|
1495
1495
|
}
|
|
@@ -1505,15 +1505,15 @@ function equals$k(existing, incoming) {
|
|
|
1505
1505
|
if (!(existing_safetyScoreRepresentation === incoming_safetyScoreRepresentation
|
|
1506
1506
|
|| (existing_safetyScoreRepresentation != null &&
|
|
1507
1507
|
incoming_safetyScoreRepresentation != null &&
|
|
1508
|
-
equals$
|
|
1508
|
+
equals$o(existing_safetyScoreRepresentation, incoming_safetyScoreRepresentation)))) {
|
|
1509
1509
|
return false;
|
|
1510
1510
|
}
|
|
1511
1511
|
}
|
|
1512
1512
|
return true;
|
|
1513
1513
|
}
|
|
1514
1514
|
|
|
1515
|
-
const VERSION$
|
|
1516
|
-
function validate$
|
|
1515
|
+
const VERSION$m = "379fd960d1a0118f506f458ab2c8dd7e";
|
|
1516
|
+
function validate$s(obj, path = 'WrappedMap') {
|
|
1517
1517
|
const v_error = (() => {
|
|
1518
1518
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
1519
1519
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -1535,10 +1535,10 @@ function validate$p(obj, path = 'WrappedMap') {
|
|
|
1535
1535
|
})();
|
|
1536
1536
|
return v_error === undefined ? null : v_error;
|
|
1537
1537
|
}
|
|
1538
|
-
const select$
|
|
1538
|
+
const select$C = function WrappedMapSelect() {
|
|
1539
1539
|
return {
|
|
1540
1540
|
kind: 'Fragment',
|
|
1541
|
-
version: VERSION$
|
|
1541
|
+
version: VERSION$m,
|
|
1542
1542
|
private: [],
|
|
1543
1543
|
selections: [
|
|
1544
1544
|
{
|
|
@@ -1549,7 +1549,7 @@ const select$y = function WrappedMapSelect() {
|
|
|
1549
1549
|
]
|
|
1550
1550
|
};
|
|
1551
1551
|
};
|
|
1552
|
-
function equals$
|
|
1552
|
+
function equals$m(existing, incoming) {
|
|
1553
1553
|
const existing_wrappedMap = existing.wrappedMap;
|
|
1554
1554
|
const incoming_wrappedMap = incoming.wrappedMap;
|
|
1555
1555
|
const equals_wrappedMap_props = equalsObject(existing_wrappedMap, incoming_wrappedMap, (existing_wrappedMap_prop, incoming_wrappedMap_prop) => {
|
|
@@ -1563,9 +1563,9 @@ function equals$j(existing, incoming) {
|
|
|
1563
1563
|
return true;
|
|
1564
1564
|
}
|
|
1565
1565
|
|
|
1566
|
-
const TTL$
|
|
1567
|
-
const VERSION$
|
|
1568
|
-
function validate$
|
|
1566
|
+
const TTL$9 = 100;
|
|
1567
|
+
const VERSION$l = "d8abd72a42e842b253da1c38954dafbc";
|
|
1568
|
+
function validate$r(obj, path = 'EinsteinLlmGenerationsRepresentation') {
|
|
1569
1569
|
const v_error = (() => {
|
|
1570
1570
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
1571
1571
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -1578,7 +1578,7 @@ function validate$o(obj, path = 'EinsteinLlmGenerationsRepresentation') {
|
|
|
1578
1578
|
for (let i = 0; i < obj_generations.length; i++) {
|
|
1579
1579
|
const obj_generations_item = obj_generations[i];
|
|
1580
1580
|
const path_generations_item = path_generations + '[' + i + ']';
|
|
1581
|
-
const referencepath_generations_itemValidationError = validate$
|
|
1581
|
+
const referencepath_generations_itemValidationError = validate$t(obj_generations_item, path_generations_item);
|
|
1582
1582
|
if (referencepath_generations_itemValidationError !== null) {
|
|
1583
1583
|
let message = 'Object doesn\'t match EinsteinLlmGenerationItemRepresentation (at "' + path_generations_item + '")\n';
|
|
1584
1584
|
message += referencepath_generations_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -1589,7 +1589,7 @@ function validate$o(obj, path = 'EinsteinLlmGenerationsRepresentation') {
|
|
|
1589
1589
|
const path_parameters = path + '.parameters';
|
|
1590
1590
|
let obj_parameters_union0 = null;
|
|
1591
1591
|
const obj_parameters_union0_error = (() => {
|
|
1592
|
-
const referencepath_parametersValidationError = validate$
|
|
1592
|
+
const referencepath_parametersValidationError = validate$s(obj_parameters, path_parameters);
|
|
1593
1593
|
if (referencepath_parametersValidationError !== null) {
|
|
1594
1594
|
let message = 'Object doesn\'t match WrappedMap (at "' + path_parameters + '")\n';
|
|
1595
1595
|
message += referencepath_parametersValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -1648,25 +1648,25 @@ function validate$o(obj, path = 'EinsteinLlmGenerationsRepresentation') {
|
|
|
1648
1648
|
})();
|
|
1649
1649
|
return v_error === undefined ? null : v_error;
|
|
1650
1650
|
}
|
|
1651
|
-
const RepresentationType$
|
|
1652
|
-
function keyBuilder$
|
|
1653
|
-
return keyPrefix + '::' + RepresentationType$
|
|
1651
|
+
const RepresentationType$9 = 'EinsteinLlmGenerationsRepresentation';
|
|
1652
|
+
function keyBuilder$m(luvio, config) {
|
|
1653
|
+
return keyPrefix + '::' + RepresentationType$9 + ':' + config.requestId;
|
|
1654
1654
|
}
|
|
1655
1655
|
function keyBuilderFromType$2(luvio, object) {
|
|
1656
1656
|
const keyParams = {
|
|
1657
1657
|
requestId: object.requestId
|
|
1658
1658
|
};
|
|
1659
|
-
return keyBuilder$
|
|
1659
|
+
return keyBuilder$m(luvio, keyParams);
|
|
1660
1660
|
}
|
|
1661
|
-
function normalize$
|
|
1661
|
+
function normalize$9(input, existing, path, luvio, store, timestamp) {
|
|
1662
1662
|
return input;
|
|
1663
1663
|
}
|
|
1664
|
-
const select$
|
|
1665
|
-
const { selections: EinsteinLlmGenerationItemRepresentation__selections, opaque: EinsteinLlmGenerationItemRepresentation__opaque, } = select$
|
|
1666
|
-
const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$
|
|
1664
|
+
const select$B = function EinsteinLlmGenerationsRepresentationSelect() {
|
|
1665
|
+
const { selections: EinsteinLlmGenerationItemRepresentation__selections, opaque: EinsteinLlmGenerationItemRepresentation__opaque, } = select$D();
|
|
1666
|
+
const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$C();
|
|
1667
1667
|
return {
|
|
1668
1668
|
kind: 'Fragment',
|
|
1669
|
-
version: VERSION$
|
|
1669
|
+
version: VERSION$l,
|
|
1670
1670
|
private: [],
|
|
1671
1671
|
selections: [
|
|
1672
1672
|
{
|
|
@@ -1692,7 +1692,7 @@ const select$x = function EinsteinLlmGenerationsRepresentationSelect() {
|
|
|
1692
1692
|
]
|
|
1693
1693
|
};
|
|
1694
1694
|
};
|
|
1695
|
-
function equals$
|
|
1695
|
+
function equals$l(existing, incoming) {
|
|
1696
1696
|
const existing_requestId = existing.requestId;
|
|
1697
1697
|
const incoming_requestId = incoming.requestId;
|
|
1698
1698
|
if (!(existing_requestId === incoming_requestId)) {
|
|
@@ -1701,7 +1701,7 @@ function equals$i(existing, incoming) {
|
|
|
1701
1701
|
const existing_generations = existing.generations;
|
|
1702
1702
|
const incoming_generations = incoming.generations;
|
|
1703
1703
|
const equals_generations_items = equalsArray(existing_generations, incoming_generations, (existing_generations_item, incoming_generations_item) => {
|
|
1704
|
-
if (!(equals$
|
|
1704
|
+
if (!(equals$n(existing_generations_item, incoming_generations_item))) {
|
|
1705
1705
|
return false;
|
|
1706
1706
|
}
|
|
1707
1707
|
});
|
|
@@ -1713,7 +1713,7 @@ function equals$i(existing, incoming) {
|
|
|
1713
1713
|
if (!(existing_parameters === incoming_parameters
|
|
1714
1714
|
|| (existing_parameters != null &&
|
|
1715
1715
|
incoming_parameters != null &&
|
|
1716
|
-
equals$
|
|
1716
|
+
equals$m(existing_parameters, incoming_parameters)))) {
|
|
1717
1717
|
return false;
|
|
1718
1718
|
}
|
|
1719
1719
|
const existing_prompt = existing.prompt;
|
|
@@ -1723,41 +1723,41 @@ function equals$i(existing, incoming) {
|
|
|
1723
1723
|
}
|
|
1724
1724
|
return true;
|
|
1725
1725
|
}
|
|
1726
|
-
const ingest$
|
|
1726
|
+
const ingest$9 = function EinsteinLlmGenerationsRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
1727
1727
|
if (process.env.NODE_ENV !== 'production') {
|
|
1728
|
-
const validateError = validate$
|
|
1728
|
+
const validateError = validate$r(input);
|
|
1729
1729
|
if (validateError !== null) {
|
|
1730
1730
|
throw validateError;
|
|
1731
1731
|
}
|
|
1732
1732
|
}
|
|
1733
1733
|
const key = keyBuilderFromType$2(luvio, input);
|
|
1734
|
-
const ttlToUse = TTL$
|
|
1735
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
1734
|
+
const ttlToUse = TTL$9;
|
|
1735
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$9, "EinsteinLLM", VERSION$l, RepresentationType$9, equals$l);
|
|
1736
1736
|
return createLink(key);
|
|
1737
1737
|
};
|
|
1738
|
-
function getTypeCacheKeys$
|
|
1738
|
+
function getTypeCacheKeys$9(rootKeySet, luvio, input, fullPathFactory) {
|
|
1739
1739
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
1740
1740
|
const rootKey = keyBuilderFromType$2(luvio, input);
|
|
1741
1741
|
rootKeySet.set(rootKey, {
|
|
1742
1742
|
namespace: keyPrefix,
|
|
1743
|
-
representationName: RepresentationType$
|
|
1743
|
+
representationName: RepresentationType$9,
|
|
1744
1744
|
mergeable: false
|
|
1745
1745
|
});
|
|
1746
1746
|
}
|
|
1747
1747
|
|
|
1748
|
-
function select$
|
|
1749
|
-
return select$
|
|
1748
|
+
function select$A(luvio, params) {
|
|
1749
|
+
return select$B();
|
|
1750
1750
|
}
|
|
1751
|
-
function getResponseCacheKeys$
|
|
1752
|
-
getTypeCacheKeys$
|
|
1751
|
+
function getResponseCacheKeys$f(storeKeyMap, luvio, resourceParams, response) {
|
|
1752
|
+
getTypeCacheKeys$9(storeKeyMap, luvio, response);
|
|
1753
1753
|
}
|
|
1754
|
-
function ingestSuccess$
|
|
1754
|
+
function ingestSuccess$f(luvio, resourceParams, response) {
|
|
1755
1755
|
const { body } = response;
|
|
1756
1756
|
const key = keyBuilderFromType$2(luvio, body);
|
|
1757
|
-
luvio.storeIngest(key, ingest$
|
|
1757
|
+
luvio.storeIngest(key, ingest$9, body);
|
|
1758
1758
|
const snapshot = luvio.storeLookup({
|
|
1759
1759
|
recordId: key,
|
|
1760
|
-
node: select$
|
|
1760
|
+
node: select$A(),
|
|
1761
1761
|
variables: {},
|
|
1762
1762
|
});
|
|
1763
1763
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -1768,7 +1768,7 @@ function ingestSuccess$e(luvio, resourceParams, response) {
|
|
|
1768
1768
|
deepFreeze(snapshot.data);
|
|
1769
1769
|
return snapshot;
|
|
1770
1770
|
}
|
|
1771
|
-
function createResourceRequest$
|
|
1771
|
+
function createResourceRequest$f(config) {
|
|
1772
1772
|
const headers = {};
|
|
1773
1773
|
return {
|
|
1774
1774
|
baseUri: '/services/data/v65.0',
|
|
@@ -1782,45 +1782,45 @@ function createResourceRequest$e(config) {
|
|
|
1782
1782
|
};
|
|
1783
1783
|
}
|
|
1784
1784
|
|
|
1785
|
-
const adapterName$
|
|
1785
|
+
const adapterName$f = 'createGenerations';
|
|
1786
1786
|
const createGenerations_ConfigPropertyMetadata = [
|
|
1787
1787
|
generateParamConfigMetadata('generationsInput', true, 2 /* Body */, 4 /* Unsupported */),
|
|
1788
1788
|
];
|
|
1789
|
-
const createGenerations_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
1790
|
-
const createResourceParams$
|
|
1791
|
-
function typeCheckConfig$
|
|
1789
|
+
const createGenerations_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$f, createGenerations_ConfigPropertyMetadata);
|
|
1790
|
+
const createResourceParams$f = /*#__PURE__*/ createResourceParams$i(createGenerations_ConfigPropertyMetadata);
|
|
1791
|
+
function typeCheckConfig$f(untrustedConfig) {
|
|
1792
1792
|
const config = {};
|
|
1793
1793
|
const untrustedConfig_generationsInput = untrustedConfig.generationsInput;
|
|
1794
|
-
const referenceEinsteinLlmGenerationsInputRepresentationValidationError = validate$
|
|
1794
|
+
const referenceEinsteinLlmGenerationsInputRepresentationValidationError = validate$w(untrustedConfig_generationsInput);
|
|
1795
1795
|
if (referenceEinsteinLlmGenerationsInputRepresentationValidationError === null) {
|
|
1796
1796
|
config.generationsInput = untrustedConfig_generationsInput;
|
|
1797
1797
|
}
|
|
1798
1798
|
return config;
|
|
1799
1799
|
}
|
|
1800
|
-
function validateAdapterConfig$
|
|
1800
|
+
function validateAdapterConfig$f(untrustedConfig, configPropertyNames) {
|
|
1801
1801
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
1802
1802
|
return null;
|
|
1803
1803
|
}
|
|
1804
1804
|
if (process.env.NODE_ENV !== 'production') {
|
|
1805
1805
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
1806
1806
|
}
|
|
1807
|
-
const config = typeCheckConfig$
|
|
1807
|
+
const config = typeCheckConfig$f(untrustedConfig);
|
|
1808
1808
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
1809
1809
|
return null;
|
|
1810
1810
|
}
|
|
1811
1811
|
return config;
|
|
1812
1812
|
}
|
|
1813
|
-
function buildNetworkSnapshot$
|
|
1814
|
-
const resourceParams = createResourceParams$
|
|
1815
|
-
const request = createResourceRequest$
|
|
1813
|
+
function buildNetworkSnapshot$f(luvio, config, options) {
|
|
1814
|
+
const resourceParams = createResourceParams$f(config);
|
|
1815
|
+
const request = createResourceRequest$f(resourceParams);
|
|
1816
1816
|
return luvio.dispatchResourceRequest(request, options)
|
|
1817
1817
|
.then((response) => {
|
|
1818
1818
|
return luvio.handleSuccessResponse(() => {
|
|
1819
|
-
const snapshot = ingestSuccess$
|
|
1819
|
+
const snapshot = ingestSuccess$f(luvio, resourceParams, response);
|
|
1820
1820
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
1821
1821
|
}, () => {
|
|
1822
1822
|
const cache = new StoreKeyMap();
|
|
1823
|
-
getResponseCacheKeys$
|
|
1823
|
+
getResponseCacheKeys$f(cache, luvio, resourceParams, response.body);
|
|
1824
1824
|
return cache;
|
|
1825
1825
|
});
|
|
1826
1826
|
}, (response) => {
|
|
@@ -1830,16 +1830,16 @@ function buildNetworkSnapshot$e(luvio, config, options) {
|
|
|
1830
1830
|
}
|
|
1831
1831
|
const createGenerationsAdapterFactory = (luvio) => {
|
|
1832
1832
|
return function createGenerations(untrustedConfig) {
|
|
1833
|
-
const config = validateAdapterConfig$
|
|
1833
|
+
const config = validateAdapterConfig$f(untrustedConfig, createGenerations_ConfigPropertyNames);
|
|
1834
1834
|
// Invalid or incomplete config
|
|
1835
1835
|
if (config === null) {
|
|
1836
1836
|
throw new Error('Invalid config for "createGenerations"');
|
|
1837
1837
|
}
|
|
1838
|
-
return buildNetworkSnapshot$
|
|
1838
|
+
return buildNetworkSnapshot$f(luvio, config);
|
|
1839
1839
|
};
|
|
1840
1840
|
};
|
|
1841
1841
|
|
|
1842
|
-
function validate$
|
|
1842
|
+
function validate$q(obj, path = 'EinsteinPromptRecordFieldRepresentation') {
|
|
1843
1843
|
const v_error = (() => {
|
|
1844
1844
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
1845
1845
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -1899,9 +1899,9 @@ function validate$n(obj, path = 'EinsteinPromptRecordFieldRepresentation') {
|
|
|
1899
1899
|
return v_error === undefined ? null : v_error;
|
|
1900
1900
|
}
|
|
1901
1901
|
|
|
1902
|
-
const TTL$
|
|
1903
|
-
const VERSION$
|
|
1904
|
-
function validate$
|
|
1902
|
+
const TTL$8 = 100;
|
|
1903
|
+
const VERSION$k = "2d1628544b54fc1701aa9b4eff05127b";
|
|
1904
|
+
function validate$p(obj, path = 'EinsteinPromptRecordRepresentation') {
|
|
1905
1905
|
const v_error = (() => {
|
|
1906
1906
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
1907
1907
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -1930,7 +1930,7 @@ function validate$m(obj, path = 'EinsteinPromptRecordRepresentation') {
|
|
|
1930
1930
|
for (let i = 0; i < obj_childRelationships_prop.length; i++) {
|
|
1931
1931
|
const obj_childRelationships_prop_item = obj_childRelationships_prop[i];
|
|
1932
1932
|
const path_childRelationships_prop_item = path_childRelationships_prop + '[' + i + ']';
|
|
1933
|
-
const referencepath_childRelationships_prop_itemValidationError = validate$
|
|
1933
|
+
const referencepath_childRelationships_prop_itemValidationError = validate$p(obj_childRelationships_prop_item, path_childRelationships_prop_item);
|
|
1934
1934
|
if (referencepath_childRelationships_prop_itemValidationError !== null) {
|
|
1935
1935
|
let message = 'Object doesn\'t match EinsteinPromptRecordRepresentation (at "' + path_childRelationships_prop_item + '")\n';
|
|
1936
1936
|
message += referencepath_childRelationships_prop_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -1950,7 +1950,7 @@ function validate$m(obj, path = 'EinsteinPromptRecordRepresentation') {
|
|
|
1950
1950
|
const key = obj_fields_keys[i];
|
|
1951
1951
|
const obj_fields_prop = obj_fields[key];
|
|
1952
1952
|
const path_fields_prop = path_fields + '["' + key + '"]';
|
|
1953
|
-
const referencepath_fields_propValidationError = validate$
|
|
1953
|
+
const referencepath_fields_propValidationError = validate$q(obj_fields_prop, path_fields_prop);
|
|
1954
1954
|
if (referencepath_fields_propValidationError !== null) {
|
|
1955
1955
|
let message = 'Object doesn\'t match EinsteinPromptRecordFieldRepresentation (at "' + path_fields_prop + '")\n';
|
|
1956
1956
|
message += referencepath_fields_propValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -1968,49 +1968,49 @@ function validate$m(obj, path = 'EinsteinPromptRecordRepresentation') {
|
|
|
1968
1968
|
})();
|
|
1969
1969
|
return v_error === undefined ? null : v_error;
|
|
1970
1970
|
}
|
|
1971
|
-
const RepresentationType$
|
|
1972
|
-
function normalize$
|
|
1971
|
+
const RepresentationType$8 = 'EinsteinPromptRecordRepresentation';
|
|
1972
|
+
function normalize$8(input, existing, path, luvio, store, timestamp) {
|
|
1973
1973
|
return input;
|
|
1974
1974
|
}
|
|
1975
|
-
const select$
|
|
1975
|
+
const select$z = function EinsteinPromptRecordRepresentationSelect() {
|
|
1976
1976
|
return {
|
|
1977
1977
|
kind: 'Fragment',
|
|
1978
|
-
version: VERSION$
|
|
1978
|
+
version: VERSION$k,
|
|
1979
1979
|
private: [],
|
|
1980
1980
|
opaque: true
|
|
1981
1981
|
};
|
|
1982
1982
|
};
|
|
1983
|
-
function equals$
|
|
1983
|
+
function equals$k(existing, incoming) {
|
|
1984
1984
|
if (JSONStringify(incoming) !== JSONStringify(existing)) {
|
|
1985
1985
|
return false;
|
|
1986
1986
|
}
|
|
1987
1987
|
return true;
|
|
1988
1988
|
}
|
|
1989
|
-
const ingest$
|
|
1989
|
+
const ingest$8 = function EinsteinPromptRecordRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
1990
1990
|
if (process.env.NODE_ENV !== 'production') {
|
|
1991
|
-
const validateError = validate$
|
|
1991
|
+
const validateError = validate$p(input);
|
|
1992
1992
|
if (validateError !== null) {
|
|
1993
1993
|
throw validateError;
|
|
1994
1994
|
}
|
|
1995
1995
|
}
|
|
1996
1996
|
const key = path.fullPath;
|
|
1997
|
-
const ttlToUse = TTL$
|
|
1998
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
1997
|
+
const ttlToUse = TTL$8;
|
|
1998
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$8, "EinsteinLLM", VERSION$k, RepresentationType$8, equals$k);
|
|
1999
1999
|
return createLink(key);
|
|
2000
2000
|
};
|
|
2001
|
-
function getTypeCacheKeys$
|
|
2001
|
+
function getTypeCacheKeys$8(rootKeySet, luvio, input, fullPathFactory) {
|
|
2002
2002
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
2003
2003
|
const rootKey = fullPathFactory();
|
|
2004
2004
|
rootKeySet.set(rootKey, {
|
|
2005
2005
|
namespace: keyPrefix,
|
|
2006
|
-
representationName: RepresentationType$
|
|
2006
|
+
representationName: RepresentationType$8,
|
|
2007
2007
|
mergeable: false
|
|
2008
2008
|
});
|
|
2009
2009
|
}
|
|
2010
2010
|
|
|
2011
|
-
const TTL$
|
|
2012
|
-
const VERSION$
|
|
2013
|
-
function validate$
|
|
2011
|
+
const TTL$7 = 100;
|
|
2012
|
+
const VERSION$j = "5fd7b8a03d155ba601bcb4ee725e0893";
|
|
2013
|
+
function validate$o(obj, path = 'EinsteinPromptRecordCollectionOutputRepresentation') {
|
|
2014
2014
|
const v_error = (() => {
|
|
2015
2015
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
2016
2016
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -2029,7 +2029,7 @@ function validate$l(obj, path = 'EinsteinPromptRecordCollectionOutputRepresentat
|
|
|
2029
2029
|
for (let i = 0; i < obj_promptRecords.length; i++) {
|
|
2030
2030
|
const obj_promptRecords_item = obj_promptRecords[i];
|
|
2031
2031
|
const path_promptRecords_item = path_promptRecords + '[' + i + ']';
|
|
2032
|
-
const referencepath_promptRecords_itemValidationError = validate$
|
|
2032
|
+
const referencepath_promptRecords_itemValidationError = validate$p(obj_promptRecords_item, path_promptRecords_item);
|
|
2033
2033
|
if (referencepath_promptRecords_itemValidationError !== null) {
|
|
2034
2034
|
let message = 'Object doesn\'t match EinsteinPromptRecordRepresentation (at "' + path_promptRecords_item + '")\n';
|
|
2035
2035
|
message += referencepath_promptRecords_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -2045,62 +2045,62 @@ function validate$l(obj, path = 'EinsteinPromptRecordCollectionOutputRepresentat
|
|
|
2045
2045
|
})();
|
|
2046
2046
|
return v_error === undefined ? null : v_error;
|
|
2047
2047
|
}
|
|
2048
|
-
const RepresentationType$
|
|
2049
|
-
function normalize$
|
|
2048
|
+
const RepresentationType$7 = 'EinsteinPromptRecordCollectionOutputRepresentation';
|
|
2049
|
+
function normalize$7(input, existing, path, luvio, store, timestamp) {
|
|
2050
2050
|
return input;
|
|
2051
2051
|
}
|
|
2052
|
-
const select$
|
|
2052
|
+
const select$y = function EinsteinPromptRecordCollectionOutputRepresentationSelect() {
|
|
2053
2053
|
return {
|
|
2054
2054
|
kind: 'Fragment',
|
|
2055
|
-
version: VERSION$
|
|
2055
|
+
version: VERSION$j,
|
|
2056
2056
|
private: [],
|
|
2057
2057
|
opaque: true
|
|
2058
2058
|
};
|
|
2059
2059
|
};
|
|
2060
|
-
function equals$
|
|
2060
|
+
function equals$j(existing, incoming) {
|
|
2061
2061
|
if (JSONStringify(incoming) !== JSONStringify(existing)) {
|
|
2062
2062
|
return false;
|
|
2063
2063
|
}
|
|
2064
2064
|
return true;
|
|
2065
2065
|
}
|
|
2066
|
-
const ingest$
|
|
2066
|
+
const ingest$7 = function EinsteinPromptRecordCollectionOutputRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
2067
2067
|
if (process.env.NODE_ENV !== 'production') {
|
|
2068
|
-
const validateError = validate$
|
|
2068
|
+
const validateError = validate$o(input);
|
|
2069
2069
|
if (validateError !== null) {
|
|
2070
2070
|
throw validateError;
|
|
2071
2071
|
}
|
|
2072
2072
|
}
|
|
2073
2073
|
const key = path.fullPath;
|
|
2074
|
-
const ttlToUse = TTL$
|
|
2075
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
2074
|
+
const ttlToUse = TTL$7;
|
|
2075
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$7, "EinsteinLLM", VERSION$j, RepresentationType$7, equals$j);
|
|
2076
2076
|
return createLink(key);
|
|
2077
2077
|
};
|
|
2078
|
-
function getTypeCacheKeys$
|
|
2078
|
+
function getTypeCacheKeys$7(rootKeySet, luvio, input, fullPathFactory) {
|
|
2079
2079
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
2080
2080
|
const rootKey = fullPathFactory();
|
|
2081
2081
|
rootKeySet.set(rootKey, {
|
|
2082
2082
|
namespace: keyPrefix,
|
|
2083
|
-
representationName: RepresentationType$
|
|
2083
|
+
representationName: RepresentationType$7,
|
|
2084
2084
|
mergeable: false
|
|
2085
2085
|
});
|
|
2086
2086
|
}
|
|
2087
2087
|
|
|
2088
|
-
function select$
|
|
2089
|
-
return select$
|
|
2088
|
+
function select$x(luvio, params) {
|
|
2089
|
+
return select$y();
|
|
2090
2090
|
}
|
|
2091
|
-
function keyBuilder$
|
|
2091
|
+
function keyBuilder$l(luvio, params) {
|
|
2092
2092
|
return keyPrefix + '::EinsteinPromptRecordCollectionOutputRepresentation:(' + 'isActive:' + params.queryParams.isActive + ',' + 'fields:' + params.queryParams.fields + ',' + 'relatedEntity:' + params.queryParams.relatedEntity + ',' + 'offset:' + params.queryParams.offset + ',' + 'pageLimit:' + params.queryParams.pageLimit + ',' + 'type:' + params.queryParams.type + ',' + 'query:' + params.queryParams.query + ',' + 'sortBy:' + params.queryParams.sortBy + ')';
|
|
2093
2093
|
}
|
|
2094
|
-
function getResponseCacheKeys$
|
|
2095
|
-
getTypeCacheKeys$
|
|
2094
|
+
function getResponseCacheKeys$e(storeKeyMap, luvio, resourceParams, response) {
|
|
2095
|
+
getTypeCacheKeys$7(storeKeyMap, luvio, response, () => keyBuilder$l(luvio, resourceParams));
|
|
2096
2096
|
}
|
|
2097
|
-
function ingestSuccess$
|
|
2097
|
+
function ingestSuccess$e(luvio, resourceParams, response, snapshotRefresh) {
|
|
2098
2098
|
const { body } = response;
|
|
2099
|
-
const key = keyBuilder$
|
|
2100
|
-
luvio.storeIngest(key, ingest$
|
|
2099
|
+
const key = keyBuilder$l(luvio, resourceParams);
|
|
2100
|
+
luvio.storeIngest(key, ingest$7, body);
|
|
2101
2101
|
const snapshot = luvio.storeLookup({
|
|
2102
2102
|
recordId: key,
|
|
2103
|
-
node: select$
|
|
2103
|
+
node: select$x(),
|
|
2104
2104
|
variables: {},
|
|
2105
2105
|
}, snapshotRefresh);
|
|
2106
2106
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -2111,19 +2111,19 @@ function ingestSuccess$d(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
2111
2111
|
deepFreeze(snapshot.data);
|
|
2112
2112
|
return snapshot;
|
|
2113
2113
|
}
|
|
2114
|
-
function ingestError$
|
|
2115
|
-
const key = keyBuilder$
|
|
2114
|
+
function ingestError$9(luvio, params, error, snapshotRefresh) {
|
|
2115
|
+
const key = keyBuilder$l(luvio, params);
|
|
2116
2116
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
2117
2117
|
const storeMetadataParams = {
|
|
2118
|
-
ttl: TTL$
|
|
2118
|
+
ttl: TTL$7,
|
|
2119
2119
|
namespace: keyPrefix,
|
|
2120
|
-
version: VERSION$
|
|
2121
|
-
representationName: RepresentationType$
|
|
2120
|
+
version: VERSION$j,
|
|
2121
|
+
representationName: RepresentationType$7
|
|
2122
2122
|
};
|
|
2123
2123
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
2124
2124
|
return errorSnapshot;
|
|
2125
2125
|
}
|
|
2126
|
-
function createResourceRequest$
|
|
2126
|
+
function createResourceRequest$e(config) {
|
|
2127
2127
|
const headers = {};
|
|
2128
2128
|
return {
|
|
2129
2129
|
baseUri: '/services/data/v65.0',
|
|
@@ -2137,7 +2137,7 @@ function createResourceRequest$d(config) {
|
|
|
2137
2137
|
};
|
|
2138
2138
|
}
|
|
2139
2139
|
|
|
2140
|
-
const adapterName$
|
|
2140
|
+
const adapterName$e = 'getPromptTemplates';
|
|
2141
2141
|
const getPromptTemplates_ConfigPropertyMetadata = [
|
|
2142
2142
|
generateParamConfigMetadata('isActive', false, 1 /* QueryParameter */, 1 /* Boolean */),
|
|
2143
2143
|
generateParamConfigMetadata('fields', false, 1 /* QueryParameter */, 0 /* String */, true),
|
|
@@ -2148,91 +2148,91 @@ const getPromptTemplates_ConfigPropertyMetadata = [
|
|
|
2148
2148
|
generateParamConfigMetadata('query', false, 1 /* QueryParameter */, 0 /* String */),
|
|
2149
2149
|
generateParamConfigMetadata('sortBy', false, 1 /* QueryParameter */, 0 /* String */),
|
|
2150
2150
|
];
|
|
2151
|
-
const getPromptTemplates_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
2152
|
-
const createResourceParams$
|
|
2153
|
-
function keyBuilder$
|
|
2154
|
-
const resourceParams = createResourceParams$
|
|
2155
|
-
return keyBuilder$
|
|
2151
|
+
const getPromptTemplates_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$e, getPromptTemplates_ConfigPropertyMetadata);
|
|
2152
|
+
const createResourceParams$e = /*#__PURE__*/ createResourceParams$i(getPromptTemplates_ConfigPropertyMetadata);
|
|
2153
|
+
function keyBuilder$k(luvio, config) {
|
|
2154
|
+
const resourceParams = createResourceParams$e(config);
|
|
2155
|
+
return keyBuilder$l(luvio, resourceParams);
|
|
2156
2156
|
}
|
|
2157
|
-
function typeCheckConfig$
|
|
2157
|
+
function typeCheckConfig$e(untrustedConfig) {
|
|
2158
2158
|
const config = {};
|
|
2159
|
-
typeCheckConfig$
|
|
2159
|
+
typeCheckConfig$i(untrustedConfig, config, getPromptTemplates_ConfigPropertyMetadata);
|
|
2160
2160
|
return config;
|
|
2161
2161
|
}
|
|
2162
|
-
function validateAdapterConfig$
|
|
2162
|
+
function validateAdapterConfig$e(untrustedConfig, configPropertyNames) {
|
|
2163
2163
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
2164
2164
|
return null;
|
|
2165
2165
|
}
|
|
2166
2166
|
if (process.env.NODE_ENV !== 'production') {
|
|
2167
2167
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
2168
2168
|
}
|
|
2169
|
-
const config = typeCheckConfig$
|
|
2169
|
+
const config = typeCheckConfig$e(untrustedConfig);
|
|
2170
2170
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
2171
2171
|
return null;
|
|
2172
2172
|
}
|
|
2173
2173
|
return config;
|
|
2174
2174
|
}
|
|
2175
|
-
function adapterFragment$
|
|
2176
|
-
createResourceParams$
|
|
2177
|
-
return select$
|
|
2175
|
+
function adapterFragment$9(luvio, config) {
|
|
2176
|
+
createResourceParams$e(config);
|
|
2177
|
+
return select$x();
|
|
2178
2178
|
}
|
|
2179
|
-
function onFetchResponseSuccess$
|
|
2180
|
-
const snapshot = ingestSuccess$
|
|
2179
|
+
function onFetchResponseSuccess$9(luvio, config, resourceParams, response) {
|
|
2180
|
+
const snapshot = ingestSuccess$e(luvio, resourceParams, response, {
|
|
2181
2181
|
config,
|
|
2182
|
-
resolve: () => buildNetworkSnapshot$
|
|
2182
|
+
resolve: () => buildNetworkSnapshot$e(luvio, config, snapshotRefreshOptions)
|
|
2183
2183
|
});
|
|
2184
2184
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
2185
2185
|
}
|
|
2186
|
-
function onFetchResponseError$
|
|
2187
|
-
const snapshot = ingestError$
|
|
2186
|
+
function onFetchResponseError$9(luvio, config, resourceParams, response) {
|
|
2187
|
+
const snapshot = ingestError$9(luvio, resourceParams, response, {
|
|
2188
2188
|
config,
|
|
2189
|
-
resolve: () => buildNetworkSnapshot$
|
|
2189
|
+
resolve: () => buildNetworkSnapshot$e(luvio, config, snapshotRefreshOptions)
|
|
2190
2190
|
});
|
|
2191
2191
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
2192
2192
|
}
|
|
2193
|
-
function buildNetworkSnapshot$
|
|
2194
|
-
const resourceParams = createResourceParams$
|
|
2195
|
-
const request = createResourceRequest$
|
|
2193
|
+
function buildNetworkSnapshot$e(luvio, config, options) {
|
|
2194
|
+
const resourceParams = createResourceParams$e(config);
|
|
2195
|
+
const request = createResourceRequest$e(resourceParams);
|
|
2196
2196
|
return luvio.dispatchResourceRequest(request, options)
|
|
2197
2197
|
.then((response) => {
|
|
2198
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
2198
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$9(luvio, config, resourceParams, response), () => {
|
|
2199
2199
|
const cache = new StoreKeyMap();
|
|
2200
|
-
getResponseCacheKeys$
|
|
2200
|
+
getResponseCacheKeys$e(cache, luvio, resourceParams, response.body);
|
|
2201
2201
|
return cache;
|
|
2202
2202
|
});
|
|
2203
2203
|
}, (response) => {
|
|
2204
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
2204
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$9(luvio, config, resourceParams, response));
|
|
2205
2205
|
});
|
|
2206
2206
|
}
|
|
2207
|
-
function buildNetworkSnapshotCachePolicy$
|
|
2208
|
-
return buildNetworkSnapshotCachePolicy$
|
|
2207
|
+
function buildNetworkSnapshotCachePolicy$9(context, coercedAdapterRequestContext) {
|
|
2208
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$e, undefined, false);
|
|
2209
2209
|
}
|
|
2210
|
-
function buildCachedSnapshotCachePolicy$
|
|
2210
|
+
function buildCachedSnapshotCachePolicy$9(context, storeLookup) {
|
|
2211
2211
|
const { luvio, config } = context;
|
|
2212
2212
|
const selector = {
|
|
2213
|
-
recordId: keyBuilder$
|
|
2214
|
-
node: adapterFragment$
|
|
2213
|
+
recordId: keyBuilder$k(luvio, config),
|
|
2214
|
+
node: adapterFragment$9(luvio, config),
|
|
2215
2215
|
variables: {},
|
|
2216
2216
|
};
|
|
2217
2217
|
const cacheSnapshot = storeLookup(selector, {
|
|
2218
2218
|
config,
|
|
2219
|
-
resolve: () => buildNetworkSnapshot$
|
|
2219
|
+
resolve: () => buildNetworkSnapshot$e(luvio, config, snapshotRefreshOptions)
|
|
2220
2220
|
});
|
|
2221
2221
|
return cacheSnapshot;
|
|
2222
2222
|
}
|
|
2223
2223
|
const getPromptTemplatesAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplates(untrustedConfig, requestContext) {
|
|
2224
|
-
const config = validateAdapterConfig$
|
|
2224
|
+
const config = validateAdapterConfig$e(untrustedConfig, getPromptTemplates_ConfigPropertyNames);
|
|
2225
2225
|
// Invalid or incomplete config
|
|
2226
2226
|
if (config === null) {
|
|
2227
2227
|
return null;
|
|
2228
2228
|
}
|
|
2229
2229
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
2230
|
-
buildCachedSnapshotCachePolicy$
|
|
2230
|
+
buildCachedSnapshotCachePolicy$9, buildNetworkSnapshotCachePolicy$9);
|
|
2231
2231
|
};
|
|
2232
2232
|
|
|
2233
|
-
const TTL$
|
|
2234
|
-
const VERSION$
|
|
2235
|
-
function validate$
|
|
2233
|
+
const TTL$6 = 100;
|
|
2234
|
+
const VERSION$i = "a90a51578e2fdd7a9741d310bed22b1d";
|
|
2235
|
+
function validate$n(obj, path = 'EinsteinPromptTemplateRepresentation') {
|
|
2236
2236
|
const v_error = (() => {
|
|
2237
2237
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
2238
2238
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -2240,7 +2240,7 @@ function validate$k(obj, path = 'EinsteinPromptTemplateRepresentation') {
|
|
|
2240
2240
|
if (obj.additionalData !== undefined) {
|
|
2241
2241
|
const obj_additionalData = obj.additionalData;
|
|
2242
2242
|
const path_additionalData = path + '.additionalData';
|
|
2243
|
-
const referencepath_additionalDataValidationError = validate$
|
|
2243
|
+
const referencepath_additionalDataValidationError = validate$s(obj_additionalData, path_additionalData);
|
|
2244
2244
|
if (referencepath_additionalDataValidationError !== null) {
|
|
2245
2245
|
let message = 'Object doesn\'t match WrappedMap (at "' + path_additionalData + '")\n';
|
|
2246
2246
|
message += referencepath_additionalDataValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -2308,24 +2308,24 @@ function validate$k(obj, path = 'EinsteinPromptTemplateRepresentation') {
|
|
|
2308
2308
|
})();
|
|
2309
2309
|
return v_error === undefined ? null : v_error;
|
|
2310
2310
|
}
|
|
2311
|
-
const RepresentationType$
|
|
2312
|
-
function keyBuilder$
|
|
2313
|
-
return keyPrefix + '::' + RepresentationType$
|
|
2311
|
+
const RepresentationType$6 = 'EinsteinPromptTemplateRepresentation';
|
|
2312
|
+
function keyBuilder$j(luvio, config) {
|
|
2313
|
+
return keyPrefix + '::' + RepresentationType$6 + ':' + config.versionId;
|
|
2314
2314
|
}
|
|
2315
2315
|
function keyBuilderFromType$1(luvio, object) {
|
|
2316
2316
|
const keyParams = {
|
|
2317
2317
|
versionId: object.versionId
|
|
2318
2318
|
};
|
|
2319
|
-
return keyBuilder$
|
|
2319
|
+
return keyBuilder$j(luvio, keyParams);
|
|
2320
2320
|
}
|
|
2321
|
-
function normalize$
|
|
2321
|
+
function normalize$6(input, existing, path, luvio, store, timestamp) {
|
|
2322
2322
|
return input;
|
|
2323
2323
|
}
|
|
2324
|
-
const select$
|
|
2325
|
-
const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$
|
|
2324
|
+
const select$w = function EinsteinPromptTemplateRepresentationSelect() {
|
|
2325
|
+
const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$C();
|
|
2326
2326
|
return {
|
|
2327
2327
|
kind: 'Fragment',
|
|
2328
|
-
version: VERSION$
|
|
2328
|
+
version: VERSION$i,
|
|
2329
2329
|
private: [],
|
|
2330
2330
|
selections: [
|
|
2331
2331
|
{
|
|
@@ -2373,7 +2373,7 @@ const select$s = function EinsteinPromptTemplateRepresentationSelect() {
|
|
|
2373
2373
|
]
|
|
2374
2374
|
};
|
|
2375
2375
|
};
|
|
2376
|
-
function equals$
|
|
2376
|
+
function equals$i(existing, incoming) {
|
|
2377
2377
|
const existing_hasWarning = existing.hasWarning;
|
|
2378
2378
|
const incoming_hasWarning = incoming.hasWarning;
|
|
2379
2379
|
if (!(existing_hasWarning === incoming_hasWarning)) {
|
|
@@ -2429,7 +2429,7 @@ function equals$f(existing, incoming) {
|
|
|
2429
2429
|
if (existing_additionalData === undefined || incoming_additionalData === undefined) {
|
|
2430
2430
|
return false;
|
|
2431
2431
|
}
|
|
2432
|
-
if (!(equals$
|
|
2432
|
+
if (!(equals$m(existing_additionalData, incoming_additionalData))) {
|
|
2433
2433
|
return false;
|
|
2434
2434
|
}
|
|
2435
2435
|
}
|
|
@@ -2455,41 +2455,41 @@ function equals$f(existing, incoming) {
|
|
|
2455
2455
|
}
|
|
2456
2456
|
return true;
|
|
2457
2457
|
}
|
|
2458
|
-
const ingest$
|
|
2458
|
+
const ingest$6 = function EinsteinPromptTemplateRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
2459
2459
|
if (process.env.NODE_ENV !== 'production') {
|
|
2460
|
-
const validateError = validate$
|
|
2460
|
+
const validateError = validate$n(input);
|
|
2461
2461
|
if (validateError !== null) {
|
|
2462
2462
|
throw validateError;
|
|
2463
2463
|
}
|
|
2464
2464
|
}
|
|
2465
2465
|
const key = keyBuilderFromType$1(luvio, input);
|
|
2466
|
-
const ttlToUse = TTL$
|
|
2467
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
2466
|
+
const ttlToUse = TTL$6;
|
|
2467
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$6, "EinsteinLLM", VERSION$i, RepresentationType$6, equals$i);
|
|
2468
2468
|
return createLink(key);
|
|
2469
2469
|
};
|
|
2470
|
-
function getTypeCacheKeys$
|
|
2470
|
+
function getTypeCacheKeys$6(rootKeySet, luvio, input, fullPathFactory) {
|
|
2471
2471
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
2472
2472
|
const rootKey = keyBuilderFromType$1(luvio, input);
|
|
2473
2473
|
rootKeySet.set(rootKey, {
|
|
2474
2474
|
namespace: keyPrefix,
|
|
2475
|
-
representationName: RepresentationType$
|
|
2475
|
+
representationName: RepresentationType$6,
|
|
2476
2476
|
mergeable: false
|
|
2477
2477
|
});
|
|
2478
2478
|
}
|
|
2479
2479
|
|
|
2480
|
-
function select$
|
|
2481
|
-
return select$
|
|
2480
|
+
function select$v(luvio, params) {
|
|
2481
|
+
return select$w();
|
|
2482
2482
|
}
|
|
2483
|
-
function getResponseCacheKeys$
|
|
2484
|
-
getTypeCacheKeys$
|
|
2483
|
+
function getResponseCacheKeys$d(storeKeyMap, luvio, resourceParams, response) {
|
|
2484
|
+
getTypeCacheKeys$6(storeKeyMap, luvio, response);
|
|
2485
2485
|
}
|
|
2486
|
-
function ingestSuccess$
|
|
2486
|
+
function ingestSuccess$d(luvio, resourceParams, response) {
|
|
2487
2487
|
const { body } = response;
|
|
2488
2488
|
const key = keyBuilderFromType$1(luvio, body);
|
|
2489
|
-
luvio.storeIngest(key, ingest$
|
|
2489
|
+
luvio.storeIngest(key, ingest$6, body);
|
|
2490
2490
|
const snapshot = luvio.storeLookup({
|
|
2491
2491
|
recordId: key,
|
|
2492
|
-
node: select$
|
|
2492
|
+
node: select$v(),
|
|
2493
2493
|
variables: {},
|
|
2494
2494
|
});
|
|
2495
2495
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -2500,7 +2500,7 @@ function ingestSuccess$c(luvio, resourceParams, response) {
|
|
|
2500
2500
|
deepFreeze(snapshot.data);
|
|
2501
2501
|
return snapshot;
|
|
2502
2502
|
}
|
|
2503
|
-
function createResourceRequest$
|
|
2503
|
+
function createResourceRequest$d(config) {
|
|
2504
2504
|
const headers = {};
|
|
2505
2505
|
return {
|
|
2506
2506
|
baseUri: '/services/data/v65.0',
|
|
@@ -2514,18 +2514,18 @@ function createResourceRequest$c(config) {
|
|
|
2514
2514
|
};
|
|
2515
2515
|
}
|
|
2516
2516
|
|
|
2517
|
-
const adapterName$
|
|
2517
|
+
const adapterName$d = 'createPromptTemplate';
|
|
2518
2518
|
const createPromptTemplate_ConfigPropertyMetadata = [
|
|
2519
2519
|
generateParamConfigMetadata('apiName', true, 2 /* Body */, 0 /* String */),
|
|
2520
2520
|
generateParamConfigMetadata('childRelationships', true, 2 /* Body */, 4 /* Unsupported */),
|
|
2521
2521
|
generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */),
|
|
2522
2522
|
generateParamConfigMetadata('id', false, 2 /* Body */, 0 /* String */),
|
|
2523
2523
|
];
|
|
2524
|
-
const createPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
2525
|
-
const createResourceParams$
|
|
2526
|
-
function typeCheckConfig$
|
|
2524
|
+
const createPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$d, createPromptTemplate_ConfigPropertyMetadata);
|
|
2525
|
+
const createResourceParams$d = /*#__PURE__*/ createResourceParams$i(createPromptTemplate_ConfigPropertyMetadata);
|
|
2526
|
+
function typeCheckConfig$d(untrustedConfig) {
|
|
2527
2527
|
const config = {};
|
|
2528
|
-
typeCheckConfig$
|
|
2528
|
+
typeCheckConfig$i(untrustedConfig, config, createPromptTemplate_ConfigPropertyMetadata);
|
|
2529
2529
|
const untrustedConfig_childRelationships = untrustedConfig.childRelationships;
|
|
2530
2530
|
if (untrustedIsObject(untrustedConfig_childRelationships)) {
|
|
2531
2531
|
const untrustedConfig_childRelationships_object = {};
|
|
@@ -2558,30 +2558,30 @@ function typeCheckConfig$c(untrustedConfig) {
|
|
|
2558
2558
|
}
|
|
2559
2559
|
return config;
|
|
2560
2560
|
}
|
|
2561
|
-
function validateAdapterConfig$
|
|
2561
|
+
function validateAdapterConfig$d(untrustedConfig, configPropertyNames) {
|
|
2562
2562
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
2563
2563
|
return null;
|
|
2564
2564
|
}
|
|
2565
2565
|
if (process.env.NODE_ENV !== 'production') {
|
|
2566
2566
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
2567
2567
|
}
|
|
2568
|
-
const config = typeCheckConfig$
|
|
2568
|
+
const config = typeCheckConfig$d(untrustedConfig);
|
|
2569
2569
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
2570
2570
|
return null;
|
|
2571
2571
|
}
|
|
2572
2572
|
return config;
|
|
2573
2573
|
}
|
|
2574
|
-
function buildNetworkSnapshot$
|
|
2575
|
-
const resourceParams = createResourceParams$
|
|
2576
|
-
const request = createResourceRequest$
|
|
2574
|
+
function buildNetworkSnapshot$d(luvio, config, options) {
|
|
2575
|
+
const resourceParams = createResourceParams$d(config);
|
|
2576
|
+
const request = createResourceRequest$d(resourceParams);
|
|
2577
2577
|
return luvio.dispatchResourceRequest(request, options)
|
|
2578
2578
|
.then((response) => {
|
|
2579
2579
|
return luvio.handleSuccessResponse(() => {
|
|
2580
|
-
const snapshot = ingestSuccess$
|
|
2580
|
+
const snapshot = ingestSuccess$d(luvio, resourceParams, response);
|
|
2581
2581
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
2582
2582
|
}, () => {
|
|
2583
2583
|
const cache = new StoreKeyMap();
|
|
2584
|
-
getResponseCacheKeys$
|
|
2584
|
+
getResponseCacheKeys$d(cache, luvio, resourceParams, response.body);
|
|
2585
2585
|
return cache;
|
|
2586
2586
|
});
|
|
2587
2587
|
}, (response) => {
|
|
@@ -2591,16 +2591,16 @@ function buildNetworkSnapshot$c(luvio, config, options) {
|
|
|
2591
2591
|
}
|
|
2592
2592
|
const createPromptTemplateAdapterFactory = (luvio) => {
|
|
2593
2593
|
return function createPromptTemplate(untrustedConfig) {
|
|
2594
|
-
const config = validateAdapterConfig$
|
|
2594
|
+
const config = validateAdapterConfig$d(untrustedConfig, createPromptTemplate_ConfigPropertyNames);
|
|
2595
2595
|
// Invalid or incomplete config
|
|
2596
2596
|
if (config === null) {
|
|
2597
2597
|
throw new Error('Invalid config for "createPromptTemplate"');
|
|
2598
2598
|
}
|
|
2599
|
-
return buildNetworkSnapshot$
|
|
2599
|
+
return buildNetworkSnapshot$d(luvio, config);
|
|
2600
2600
|
};
|
|
2601
2601
|
};
|
|
2602
2602
|
|
|
2603
|
-
function validate$
|
|
2603
|
+
function validate$m(obj, path = 'PromptTemplateDataProviderOutputParamRepresentation') {
|
|
2604
2604
|
const v_error = (() => {
|
|
2605
2605
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
2606
2606
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -2626,7 +2626,7 @@ function validate$j(obj, path = 'PromptTemplateDataProviderOutputParamRepresenta
|
|
|
2626
2626
|
return v_error === undefined ? null : v_error;
|
|
2627
2627
|
}
|
|
2628
2628
|
|
|
2629
|
-
function validate$
|
|
2629
|
+
function validate$l(obj, path = 'PromptTemplateDataProviderInputParamRepresentation') {
|
|
2630
2630
|
const v_error = (() => {
|
|
2631
2631
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
2632
2632
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -2655,9 +2655,9 @@ function validate$i(obj, path = 'PromptTemplateDataProviderInputParamRepresentat
|
|
|
2655
2655
|
return v_error === undefined ? null : v_error;
|
|
2656
2656
|
}
|
|
2657
2657
|
|
|
2658
|
-
const TTL$
|
|
2659
|
-
const VERSION$
|
|
2660
|
-
function validate$
|
|
2658
|
+
const TTL$5 = 300;
|
|
2659
|
+
const VERSION$h = "d4824d8c6e7848df0de89295e6d9d434";
|
|
2660
|
+
function validate$k(obj, path = 'PromptTemplateDataProviderInstanceConfigRepresentation') {
|
|
2661
2661
|
const v_error = (() => {
|
|
2662
2662
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
2663
2663
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -2686,7 +2686,7 @@ function validate$h(obj, path = 'PromptTemplateDataProviderInstanceConfigReprese
|
|
|
2686
2686
|
if (obj.defaultOutputParam !== undefined) {
|
|
2687
2687
|
const obj_defaultOutputParam = obj.defaultOutputParam;
|
|
2688
2688
|
const path_defaultOutputParam = path + '.defaultOutputParam';
|
|
2689
|
-
const referencepath_defaultOutputParamValidationError = validate$
|
|
2689
|
+
const referencepath_defaultOutputParamValidationError = validate$m(obj_defaultOutputParam, path_defaultOutputParam);
|
|
2690
2690
|
if (referencepath_defaultOutputParamValidationError !== null) {
|
|
2691
2691
|
let message = 'Object doesn\'t match PromptTemplateDataProviderOutputParamRepresentation (at "' + path_defaultOutputParam + '")\n';
|
|
2692
2692
|
message += referencepath_defaultOutputParamValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -2740,7 +2740,7 @@ function validate$h(obj, path = 'PromptTemplateDataProviderInstanceConfigReprese
|
|
|
2740
2740
|
for (let i = 0; i < obj_inputParams.length; i++) {
|
|
2741
2741
|
const obj_inputParams_item = obj_inputParams[i];
|
|
2742
2742
|
const path_inputParams_item = path_inputParams + '[' + i + ']';
|
|
2743
|
-
const referencepath_inputParams_itemValidationError = validate$
|
|
2743
|
+
const referencepath_inputParams_itemValidationError = validate$l(obj_inputParams_item, path_inputParams_item);
|
|
2744
2744
|
if (referencepath_inputParams_itemValidationError !== null) {
|
|
2745
2745
|
let message = 'Object doesn\'t match PromptTemplateDataProviderInputParamRepresentation (at "' + path_inputParams_item + '")\n';
|
|
2746
2746
|
message += referencepath_inputParams_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -2806,7 +2806,7 @@ function validate$h(obj, path = 'PromptTemplateDataProviderInstanceConfigReprese
|
|
|
2806
2806
|
for (let i = 0; i < obj_outputParams.length; i++) {
|
|
2807
2807
|
const obj_outputParams_item = obj_outputParams[i];
|
|
2808
2808
|
const path_outputParams_item = path_outputParams + '[' + i + ']';
|
|
2809
|
-
const referencepath_outputParams_itemValidationError = validate$
|
|
2809
|
+
const referencepath_outputParams_itemValidationError = validate$m(obj_outputParams_item, path_outputParams_item);
|
|
2810
2810
|
if (referencepath_outputParams_itemValidationError !== null) {
|
|
2811
2811
|
let message = 'Object doesn\'t match PromptTemplateDataProviderOutputParamRepresentation (at "' + path_outputParams_item + '")\n';
|
|
2812
2812
|
message += referencepath_outputParams_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -2878,49 +2878,49 @@ function validate$h(obj, path = 'PromptTemplateDataProviderInstanceConfigReprese
|
|
|
2878
2878
|
})();
|
|
2879
2879
|
return v_error === undefined ? null : v_error;
|
|
2880
2880
|
}
|
|
2881
|
-
const RepresentationType$
|
|
2882
|
-
function normalize$
|
|
2881
|
+
const RepresentationType$5 = 'PromptTemplateDataProviderInstanceConfigRepresentation';
|
|
2882
|
+
function normalize$5(input, existing, path, luvio, store, timestamp) {
|
|
2883
2883
|
return input;
|
|
2884
2884
|
}
|
|
2885
|
-
const select$
|
|
2885
|
+
const select$u = function PromptTemplateDataProviderInstanceConfigRepresentationSelect() {
|
|
2886
2886
|
return {
|
|
2887
2887
|
kind: 'Fragment',
|
|
2888
|
-
version: VERSION$
|
|
2888
|
+
version: VERSION$h,
|
|
2889
2889
|
private: [],
|
|
2890
2890
|
opaque: true
|
|
2891
2891
|
};
|
|
2892
2892
|
};
|
|
2893
|
-
function equals$
|
|
2893
|
+
function equals$h(existing, incoming) {
|
|
2894
2894
|
if (JSONStringify(incoming) !== JSONStringify(existing)) {
|
|
2895
2895
|
return false;
|
|
2896
2896
|
}
|
|
2897
2897
|
return true;
|
|
2898
2898
|
}
|
|
2899
|
-
const ingest$
|
|
2899
|
+
const ingest$5 = function PromptTemplateDataProviderInstanceConfigRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
2900
2900
|
if (process.env.NODE_ENV !== 'production') {
|
|
2901
|
-
const validateError = validate$
|
|
2901
|
+
const validateError = validate$k(input);
|
|
2902
2902
|
if (validateError !== null) {
|
|
2903
2903
|
throw validateError;
|
|
2904
2904
|
}
|
|
2905
2905
|
}
|
|
2906
2906
|
const key = path.fullPath;
|
|
2907
|
-
const ttlToUse = TTL$
|
|
2908
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
2907
|
+
const ttlToUse = TTL$5;
|
|
2908
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$5, "EinsteinLLM", VERSION$h, RepresentationType$5, equals$h);
|
|
2909
2909
|
return createLink(key);
|
|
2910
2910
|
};
|
|
2911
|
-
function getTypeCacheKeys$
|
|
2911
|
+
function getTypeCacheKeys$5(rootKeySet, luvio, input, fullPathFactory) {
|
|
2912
2912
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
2913
2913
|
const rootKey = fullPathFactory();
|
|
2914
2914
|
rootKeySet.set(rootKey, {
|
|
2915
2915
|
namespace: keyPrefix,
|
|
2916
|
-
representationName: RepresentationType$
|
|
2916
|
+
representationName: RepresentationType$5,
|
|
2917
2917
|
mergeable: false
|
|
2918
2918
|
});
|
|
2919
2919
|
}
|
|
2920
2920
|
|
|
2921
|
-
const TTL$
|
|
2922
|
-
const VERSION$
|
|
2923
|
-
function validate$
|
|
2921
|
+
const TTL$4 = 300;
|
|
2922
|
+
const VERSION$g = "3a6ecdfe18eb2af8f8f6aaa1a30b194c";
|
|
2923
|
+
function validate$j(obj, path = 'PromptTemplateDataProviderInstanceConfigCollectionRepresentation') {
|
|
2924
2924
|
const v_error = (() => {
|
|
2925
2925
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
2926
2926
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -2933,7 +2933,7 @@ function validate$g(obj, path = 'PromptTemplateDataProviderInstanceConfigCollect
|
|
|
2933
2933
|
for (let i = 0; i < obj_dataProviderInstanceConfigs.length; i++) {
|
|
2934
2934
|
const obj_dataProviderInstanceConfigs_item = obj_dataProviderInstanceConfigs[i];
|
|
2935
2935
|
const path_dataProviderInstanceConfigs_item = path_dataProviderInstanceConfigs + '[' + i + ']';
|
|
2936
|
-
const referencepath_dataProviderInstanceConfigs_itemValidationError = validate$
|
|
2936
|
+
const referencepath_dataProviderInstanceConfigs_itemValidationError = validate$k(obj_dataProviderInstanceConfigs_item, path_dataProviderInstanceConfigs_item);
|
|
2937
2937
|
if (referencepath_dataProviderInstanceConfigs_itemValidationError !== null) {
|
|
2938
2938
|
let message = 'Object doesn\'t match PromptTemplateDataProviderInstanceConfigRepresentation (at "' + path_dataProviderInstanceConfigs_item + '")\n';
|
|
2939
2939
|
message += referencepath_dataProviderInstanceConfigs_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -2943,62 +2943,62 @@ function validate$g(obj, path = 'PromptTemplateDataProviderInstanceConfigCollect
|
|
|
2943
2943
|
})();
|
|
2944
2944
|
return v_error === undefined ? null : v_error;
|
|
2945
2945
|
}
|
|
2946
|
-
const RepresentationType$
|
|
2947
|
-
function normalize$
|
|
2946
|
+
const RepresentationType$4 = 'PromptTemplateDataProviderInstanceConfigCollectionRepresentation';
|
|
2947
|
+
function normalize$4(input, existing, path, luvio, store, timestamp) {
|
|
2948
2948
|
return input;
|
|
2949
2949
|
}
|
|
2950
|
-
const select$
|
|
2950
|
+
const select$t = function PromptTemplateDataProviderInstanceConfigCollectionRepresentationSelect() {
|
|
2951
2951
|
return {
|
|
2952
2952
|
kind: 'Fragment',
|
|
2953
|
-
version: VERSION$
|
|
2953
|
+
version: VERSION$g,
|
|
2954
2954
|
private: [],
|
|
2955
2955
|
opaque: true
|
|
2956
2956
|
};
|
|
2957
2957
|
};
|
|
2958
|
-
function equals$
|
|
2958
|
+
function equals$g(existing, incoming) {
|
|
2959
2959
|
if (JSONStringify(incoming) !== JSONStringify(existing)) {
|
|
2960
2960
|
return false;
|
|
2961
2961
|
}
|
|
2962
2962
|
return true;
|
|
2963
2963
|
}
|
|
2964
|
-
const ingest$
|
|
2964
|
+
const ingest$4 = function PromptTemplateDataProviderInstanceConfigCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
2965
2965
|
if (process.env.NODE_ENV !== 'production') {
|
|
2966
|
-
const validateError = validate$
|
|
2966
|
+
const validateError = validate$j(input);
|
|
2967
2967
|
if (validateError !== null) {
|
|
2968
2968
|
throw validateError;
|
|
2969
2969
|
}
|
|
2970
2970
|
}
|
|
2971
2971
|
const key = path.fullPath;
|
|
2972
|
-
const ttlToUse = TTL$
|
|
2973
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
2972
|
+
const ttlToUse = TTL$4;
|
|
2973
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$4, "EinsteinLLM", VERSION$g, RepresentationType$4, equals$g);
|
|
2974
2974
|
return createLink(key);
|
|
2975
2975
|
};
|
|
2976
|
-
function getTypeCacheKeys$
|
|
2976
|
+
function getTypeCacheKeys$4(rootKeySet, luvio, input, fullPathFactory) {
|
|
2977
2977
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
2978
2978
|
const rootKey = fullPathFactory();
|
|
2979
2979
|
rootKeySet.set(rootKey, {
|
|
2980
2980
|
namespace: keyPrefix,
|
|
2981
|
-
representationName: RepresentationType$
|
|
2981
|
+
representationName: RepresentationType$4,
|
|
2982
2982
|
mergeable: false
|
|
2983
2983
|
});
|
|
2984
2984
|
}
|
|
2985
2985
|
|
|
2986
|
-
function select$
|
|
2987
|
-
return select$
|
|
2986
|
+
function select$s(luvio, params) {
|
|
2987
|
+
return select$t();
|
|
2988
2988
|
}
|
|
2989
|
-
function keyBuilder$
|
|
2989
|
+
function keyBuilder$i(luvio, params) {
|
|
2990
2990
|
return keyPrefix + '::PromptTemplateDataProviderInstanceConfigCollectionRepresentation:(' + (params.body.groupName === undefined ? 'groupName' : 'groupName:' + params.body.groupName) + '::' + (params.body.target === undefined ? 'target' : 'target:' + params.body.target) + '::' + 'templateInputs:' + params.body.templateInputs + '::' + 'templateTypeName:' + params.body.templateTypeName + ')';
|
|
2991
2991
|
}
|
|
2992
|
-
function getResponseCacheKeys$
|
|
2993
|
-
getTypeCacheKeys$
|
|
2992
|
+
function getResponseCacheKeys$c(storeKeyMap, luvio, resourceParams, response) {
|
|
2993
|
+
getTypeCacheKeys$4(storeKeyMap, luvio, response, () => keyBuilder$i(luvio, resourceParams));
|
|
2994
2994
|
}
|
|
2995
|
-
function ingestSuccess$
|
|
2995
|
+
function ingestSuccess$c(luvio, resourceParams, response, snapshotRefresh) {
|
|
2996
2996
|
const { body } = response;
|
|
2997
|
-
const key = keyBuilder$
|
|
2998
|
-
luvio.storeIngest(key, ingest$
|
|
2997
|
+
const key = keyBuilder$i(luvio, resourceParams);
|
|
2998
|
+
luvio.storeIngest(key, ingest$4, body);
|
|
2999
2999
|
const snapshot = luvio.storeLookup({
|
|
3000
3000
|
recordId: key,
|
|
3001
|
-
node: select$
|
|
3001
|
+
node: select$s(),
|
|
3002
3002
|
variables: {},
|
|
3003
3003
|
}, snapshotRefresh);
|
|
3004
3004
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -3009,19 +3009,19 @@ function ingestSuccess$b(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
3009
3009
|
deepFreeze(snapshot.data);
|
|
3010
3010
|
return snapshot;
|
|
3011
3011
|
}
|
|
3012
|
-
function ingestError$
|
|
3013
|
-
const key = keyBuilder$
|
|
3012
|
+
function ingestError$8(luvio, params, error, snapshotRefresh) {
|
|
3013
|
+
const key = keyBuilder$i(luvio, params);
|
|
3014
3014
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
3015
3015
|
const storeMetadataParams = {
|
|
3016
|
-
ttl: TTL$
|
|
3016
|
+
ttl: TTL$4,
|
|
3017
3017
|
namespace: keyPrefix,
|
|
3018
|
-
version: VERSION$
|
|
3019
|
-
representationName: RepresentationType$
|
|
3018
|
+
version: VERSION$g,
|
|
3019
|
+
representationName: RepresentationType$4
|
|
3020
3020
|
};
|
|
3021
3021
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
3022
3022
|
return errorSnapshot;
|
|
3023
3023
|
}
|
|
3024
|
-
function createResourceRequest$
|
|
3024
|
+
function createResourceRequest$c(config) {
|
|
3025
3025
|
const headers = {};
|
|
3026
3026
|
return {
|
|
3027
3027
|
baseUri: '/services/data/v65.0',
|
|
@@ -3035,22 +3035,22 @@ function createResourceRequest$b(config) {
|
|
|
3035
3035
|
};
|
|
3036
3036
|
}
|
|
3037
3037
|
|
|
3038
|
-
const adapterName$
|
|
3038
|
+
const adapterName$c = 'getInputMappedDataProviders';
|
|
3039
3039
|
const getInputMappedDataProviders_ConfigPropertyMetadata = [
|
|
3040
3040
|
generateParamConfigMetadata('groupName', false, 2 /* Body */, 0 /* String */),
|
|
3041
3041
|
generateParamConfigMetadata('target', false, 2 /* Body */, 0 /* String */),
|
|
3042
3042
|
generateParamConfigMetadata('templateInputs', true, 2 /* Body */, 4 /* Unsupported */, true),
|
|
3043
3043
|
generateParamConfigMetadata('templateTypeName', true, 2 /* Body */, 0 /* String */),
|
|
3044
3044
|
];
|
|
3045
|
-
const getInputMappedDataProviders_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
3046
|
-
const createResourceParams$
|
|
3047
|
-
function keyBuilder$
|
|
3048
|
-
const resourceParams = createResourceParams$
|
|
3049
|
-
return keyBuilder$
|
|
3045
|
+
const getInputMappedDataProviders_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$c, getInputMappedDataProviders_ConfigPropertyMetadata);
|
|
3046
|
+
const createResourceParams$c = /*#__PURE__*/ createResourceParams$i(getInputMappedDataProviders_ConfigPropertyMetadata);
|
|
3047
|
+
function keyBuilder$h(luvio, config) {
|
|
3048
|
+
const resourceParams = createResourceParams$c(config);
|
|
3049
|
+
return keyBuilder$i(luvio, resourceParams);
|
|
3050
3050
|
}
|
|
3051
|
-
function typeCheckConfig$
|
|
3051
|
+
function typeCheckConfig$c(untrustedConfig) {
|
|
3052
3052
|
const config = {};
|
|
3053
|
-
typeCheckConfig$
|
|
3053
|
+
typeCheckConfig$i(untrustedConfig, config, getInputMappedDataProviders_ConfigPropertyMetadata);
|
|
3054
3054
|
const untrustedConfig_templateInputs = untrustedConfig.templateInputs;
|
|
3055
3055
|
if (ArrayIsArray$1(untrustedConfig_templateInputs)) {
|
|
3056
3056
|
const untrustedConfig_templateInputs_array = [];
|
|
@@ -3062,93 +3062,93 @@ function typeCheckConfig$b(untrustedConfig) {
|
|
|
3062
3062
|
}
|
|
3063
3063
|
return config;
|
|
3064
3064
|
}
|
|
3065
|
-
function validateAdapterConfig$
|
|
3065
|
+
function validateAdapterConfig$c(untrustedConfig, configPropertyNames) {
|
|
3066
3066
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
3067
3067
|
return null;
|
|
3068
3068
|
}
|
|
3069
3069
|
if (process.env.NODE_ENV !== 'production') {
|
|
3070
3070
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
3071
3071
|
}
|
|
3072
|
-
const config = typeCheckConfig$
|
|
3072
|
+
const config = typeCheckConfig$c(untrustedConfig);
|
|
3073
3073
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
3074
3074
|
return null;
|
|
3075
3075
|
}
|
|
3076
3076
|
return config;
|
|
3077
3077
|
}
|
|
3078
|
-
function adapterFragment$
|
|
3079
|
-
createResourceParams$
|
|
3080
|
-
return select$
|
|
3078
|
+
function adapterFragment$8(luvio, config) {
|
|
3079
|
+
createResourceParams$c(config);
|
|
3080
|
+
return select$s();
|
|
3081
3081
|
}
|
|
3082
|
-
function onFetchResponseSuccess$
|
|
3083
|
-
const snapshot = ingestSuccess$
|
|
3082
|
+
function onFetchResponseSuccess$8(luvio, config, resourceParams, response) {
|
|
3083
|
+
const snapshot = ingestSuccess$c(luvio, resourceParams, response, {
|
|
3084
3084
|
config,
|
|
3085
|
-
resolve: () => buildNetworkSnapshot$
|
|
3085
|
+
resolve: () => buildNetworkSnapshot$c(luvio, config, snapshotRefreshOptions)
|
|
3086
3086
|
});
|
|
3087
3087
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3088
3088
|
}
|
|
3089
|
-
function onFetchResponseError$
|
|
3090
|
-
const snapshot = ingestError$
|
|
3089
|
+
function onFetchResponseError$8(luvio, config, resourceParams, response) {
|
|
3090
|
+
const snapshot = ingestError$8(luvio, resourceParams, response, {
|
|
3091
3091
|
config,
|
|
3092
|
-
resolve: () => buildNetworkSnapshot$
|
|
3092
|
+
resolve: () => buildNetworkSnapshot$c(luvio, config, snapshotRefreshOptions)
|
|
3093
3093
|
});
|
|
3094
3094
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3095
3095
|
}
|
|
3096
|
-
function buildNetworkSnapshot$
|
|
3097
|
-
const resourceParams = createResourceParams$
|
|
3098
|
-
const request = createResourceRequest$
|
|
3096
|
+
function buildNetworkSnapshot$c(luvio, config, options) {
|
|
3097
|
+
const resourceParams = createResourceParams$c(config);
|
|
3098
|
+
const request = createResourceRequest$c(resourceParams);
|
|
3099
3099
|
return luvio.dispatchResourceRequest(request, options)
|
|
3100
3100
|
.then((response) => {
|
|
3101
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
3101
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$8(luvio, config, resourceParams, response), () => {
|
|
3102
3102
|
const cache = new StoreKeyMap();
|
|
3103
|
-
getResponseCacheKeys$
|
|
3103
|
+
getResponseCacheKeys$c(cache, luvio, resourceParams, response.body);
|
|
3104
3104
|
return cache;
|
|
3105
3105
|
});
|
|
3106
3106
|
}, (response) => {
|
|
3107
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
3107
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$8(luvio, config, resourceParams, response));
|
|
3108
3108
|
});
|
|
3109
3109
|
}
|
|
3110
|
-
function buildNetworkSnapshotCachePolicy$
|
|
3111
|
-
return buildNetworkSnapshotCachePolicy$
|
|
3110
|
+
function buildNetworkSnapshotCachePolicy$8(context, coercedAdapterRequestContext) {
|
|
3111
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$c, 'get', false);
|
|
3112
3112
|
}
|
|
3113
|
-
function buildCachedSnapshotCachePolicy$
|
|
3113
|
+
function buildCachedSnapshotCachePolicy$8(context, storeLookup) {
|
|
3114
3114
|
const { luvio, config } = context;
|
|
3115
3115
|
const selector = {
|
|
3116
|
-
recordId: keyBuilder$
|
|
3117
|
-
node: adapterFragment$
|
|
3116
|
+
recordId: keyBuilder$h(luvio, config),
|
|
3117
|
+
node: adapterFragment$8(luvio, config),
|
|
3118
3118
|
variables: {},
|
|
3119
3119
|
};
|
|
3120
3120
|
const cacheSnapshot = storeLookup(selector, {
|
|
3121
3121
|
config,
|
|
3122
|
-
resolve: () => buildNetworkSnapshot$
|
|
3122
|
+
resolve: () => buildNetworkSnapshot$c(luvio, config, snapshotRefreshOptions)
|
|
3123
3123
|
});
|
|
3124
3124
|
return cacheSnapshot;
|
|
3125
3125
|
}
|
|
3126
3126
|
const getInputMappedDataProvidersAdapterFactory = (luvio) => function EinsteinLLM__getInputMappedDataProviders(untrustedConfig, requestContext) {
|
|
3127
|
-
const config = validateAdapterConfig$
|
|
3127
|
+
const config = validateAdapterConfig$c(untrustedConfig, getInputMappedDataProviders_ConfigPropertyNames);
|
|
3128
3128
|
// Invalid or incomplete config
|
|
3129
3129
|
if (config === null) {
|
|
3130
3130
|
return null;
|
|
3131
3131
|
}
|
|
3132
3132
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
3133
|
-
buildCachedSnapshotCachePolicy$
|
|
3133
|
+
buildCachedSnapshotCachePolicy$8, buildNetworkSnapshotCachePolicy$8);
|
|
3134
3134
|
};
|
|
3135
3135
|
|
|
3136
|
-
function select$
|
|
3137
|
-
return select$
|
|
3136
|
+
function select$r(luvio, params) {
|
|
3137
|
+
return select$t();
|
|
3138
3138
|
}
|
|
3139
|
-
function keyBuilder$
|
|
3139
|
+
function keyBuilder$g(luvio, params) {
|
|
3140
3140
|
return keyPrefix + '::PromptTemplateDataProviderInstanceConfigCollectionRepresentation:(' + 'groupNames:' + params.queryParams.groupNames + ',' + 'targets:' + params.queryParams.targets + ',' + 'templateType:' + params.urlParams.templateType + ')';
|
|
3141
3141
|
}
|
|
3142
|
-
function getResponseCacheKeys$
|
|
3143
|
-
getTypeCacheKeys$
|
|
3142
|
+
function getResponseCacheKeys$b(storeKeyMap, luvio, resourceParams, response) {
|
|
3143
|
+
getTypeCacheKeys$4(storeKeyMap, luvio, response, () => keyBuilder$g(luvio, resourceParams));
|
|
3144
3144
|
}
|
|
3145
|
-
function ingestSuccess$
|
|
3145
|
+
function ingestSuccess$b(luvio, resourceParams, response, snapshotRefresh) {
|
|
3146
3146
|
const { body } = response;
|
|
3147
|
-
const key = keyBuilder$
|
|
3148
|
-
luvio.storeIngest(key, ingest$
|
|
3147
|
+
const key = keyBuilder$g(luvio, resourceParams);
|
|
3148
|
+
luvio.storeIngest(key, ingest$4, body);
|
|
3149
3149
|
const snapshot = luvio.storeLookup({
|
|
3150
3150
|
recordId: key,
|
|
3151
|
-
node: select$
|
|
3151
|
+
node: select$r(),
|
|
3152
3152
|
variables: {},
|
|
3153
3153
|
}, snapshotRefresh);
|
|
3154
3154
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -3159,19 +3159,19 @@ function ingestSuccess$a(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
3159
3159
|
deepFreeze(snapshot.data);
|
|
3160
3160
|
return snapshot;
|
|
3161
3161
|
}
|
|
3162
|
-
function ingestError$
|
|
3163
|
-
const key = keyBuilder$
|
|
3162
|
+
function ingestError$7(luvio, params, error, snapshotRefresh) {
|
|
3163
|
+
const key = keyBuilder$g(luvio, params);
|
|
3164
3164
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
3165
3165
|
const storeMetadataParams = {
|
|
3166
|
-
ttl: TTL$
|
|
3166
|
+
ttl: TTL$4,
|
|
3167
3167
|
namespace: keyPrefix,
|
|
3168
|
-
version: VERSION$
|
|
3169
|
-
representationName: RepresentationType$
|
|
3168
|
+
version: VERSION$g,
|
|
3169
|
+
representationName: RepresentationType$4
|
|
3170
3170
|
};
|
|
3171
3171
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
3172
3172
|
return errorSnapshot;
|
|
3173
3173
|
}
|
|
3174
|
-
function createResourceRequest$
|
|
3174
|
+
function createResourceRequest$b(config) {
|
|
3175
3175
|
const headers = {};
|
|
3176
3176
|
return {
|
|
3177
3177
|
baseUri: '/services/data/v65.0',
|
|
@@ -3185,110 +3185,110 @@ function createResourceRequest$a(config) {
|
|
|
3185
3185
|
};
|
|
3186
3186
|
}
|
|
3187
3187
|
|
|
3188
|
-
const adapterName$
|
|
3188
|
+
const adapterName$b = 'getDataProviders';
|
|
3189
3189
|
const getDataProviders_ConfigPropertyMetadata = [
|
|
3190
3190
|
generateParamConfigMetadata('templateType', true, 0 /* UrlParameter */, 0 /* String */),
|
|
3191
3191
|
generateParamConfigMetadata('groupNames', false, 1 /* QueryParameter */, 0 /* String */, true),
|
|
3192
3192
|
generateParamConfigMetadata('targets', false, 1 /* QueryParameter */, 0 /* String */, true),
|
|
3193
3193
|
];
|
|
3194
|
-
const getDataProviders_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
3195
|
-
const createResourceParams$
|
|
3196
|
-
function keyBuilder$
|
|
3197
|
-
const resourceParams = createResourceParams$
|
|
3198
|
-
return keyBuilder$
|
|
3194
|
+
const getDataProviders_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$b, getDataProviders_ConfigPropertyMetadata);
|
|
3195
|
+
const createResourceParams$b = /*#__PURE__*/ createResourceParams$i(getDataProviders_ConfigPropertyMetadata);
|
|
3196
|
+
function keyBuilder$f(luvio, config) {
|
|
3197
|
+
const resourceParams = createResourceParams$b(config);
|
|
3198
|
+
return keyBuilder$g(luvio, resourceParams);
|
|
3199
3199
|
}
|
|
3200
|
-
function typeCheckConfig$
|
|
3200
|
+
function typeCheckConfig$b(untrustedConfig) {
|
|
3201
3201
|
const config = {};
|
|
3202
|
-
typeCheckConfig$
|
|
3202
|
+
typeCheckConfig$i(untrustedConfig, config, getDataProviders_ConfigPropertyMetadata);
|
|
3203
3203
|
return config;
|
|
3204
3204
|
}
|
|
3205
|
-
function validateAdapterConfig$
|
|
3205
|
+
function validateAdapterConfig$b(untrustedConfig, configPropertyNames) {
|
|
3206
3206
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
3207
3207
|
return null;
|
|
3208
3208
|
}
|
|
3209
3209
|
if (process.env.NODE_ENV !== 'production') {
|
|
3210
3210
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
3211
3211
|
}
|
|
3212
|
-
const config = typeCheckConfig$
|
|
3212
|
+
const config = typeCheckConfig$b(untrustedConfig);
|
|
3213
3213
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
3214
3214
|
return null;
|
|
3215
3215
|
}
|
|
3216
3216
|
return config;
|
|
3217
3217
|
}
|
|
3218
|
-
function adapterFragment$
|
|
3219
|
-
createResourceParams$
|
|
3220
|
-
return select$
|
|
3218
|
+
function adapterFragment$7(luvio, config) {
|
|
3219
|
+
createResourceParams$b(config);
|
|
3220
|
+
return select$r();
|
|
3221
3221
|
}
|
|
3222
|
-
function onFetchResponseSuccess$
|
|
3223
|
-
const snapshot = ingestSuccess$
|
|
3222
|
+
function onFetchResponseSuccess$7(luvio, config, resourceParams, response) {
|
|
3223
|
+
const snapshot = ingestSuccess$b(luvio, resourceParams, response, {
|
|
3224
3224
|
config,
|
|
3225
|
-
resolve: () => buildNetworkSnapshot$
|
|
3225
|
+
resolve: () => buildNetworkSnapshot$b(luvio, config, snapshotRefreshOptions)
|
|
3226
3226
|
});
|
|
3227
3227
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3228
3228
|
}
|
|
3229
|
-
function onFetchResponseError$
|
|
3230
|
-
const snapshot = ingestError$
|
|
3229
|
+
function onFetchResponseError$7(luvio, config, resourceParams, response) {
|
|
3230
|
+
const snapshot = ingestError$7(luvio, resourceParams, response, {
|
|
3231
3231
|
config,
|
|
3232
|
-
resolve: () => buildNetworkSnapshot$
|
|
3232
|
+
resolve: () => buildNetworkSnapshot$b(luvio, config, snapshotRefreshOptions)
|
|
3233
3233
|
});
|
|
3234
3234
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3235
3235
|
}
|
|
3236
|
-
function buildNetworkSnapshot$
|
|
3237
|
-
const resourceParams = createResourceParams$
|
|
3238
|
-
const request = createResourceRequest$
|
|
3236
|
+
function buildNetworkSnapshot$b(luvio, config, options) {
|
|
3237
|
+
const resourceParams = createResourceParams$b(config);
|
|
3238
|
+
const request = createResourceRequest$b(resourceParams);
|
|
3239
3239
|
return luvio.dispatchResourceRequest(request, options)
|
|
3240
3240
|
.then((response) => {
|
|
3241
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
3241
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$7(luvio, config, resourceParams, response), () => {
|
|
3242
3242
|
const cache = new StoreKeyMap();
|
|
3243
|
-
getResponseCacheKeys$
|
|
3243
|
+
getResponseCacheKeys$b(cache, luvio, resourceParams, response.body);
|
|
3244
3244
|
return cache;
|
|
3245
3245
|
});
|
|
3246
3246
|
}, (response) => {
|
|
3247
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
3247
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$7(luvio, config, resourceParams, response));
|
|
3248
3248
|
});
|
|
3249
3249
|
}
|
|
3250
|
-
function buildNetworkSnapshotCachePolicy$
|
|
3251
|
-
return buildNetworkSnapshotCachePolicy$
|
|
3250
|
+
function buildNetworkSnapshotCachePolicy$7(context, coercedAdapterRequestContext) {
|
|
3251
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$b, undefined, false);
|
|
3252
3252
|
}
|
|
3253
|
-
function buildCachedSnapshotCachePolicy$
|
|
3253
|
+
function buildCachedSnapshotCachePolicy$7(context, storeLookup) {
|
|
3254
3254
|
const { luvio, config } = context;
|
|
3255
3255
|
const selector = {
|
|
3256
|
-
recordId: keyBuilder$
|
|
3257
|
-
node: adapterFragment$
|
|
3256
|
+
recordId: keyBuilder$f(luvio, config),
|
|
3257
|
+
node: adapterFragment$7(luvio, config),
|
|
3258
3258
|
variables: {},
|
|
3259
3259
|
};
|
|
3260
3260
|
const cacheSnapshot = storeLookup(selector, {
|
|
3261
3261
|
config,
|
|
3262
|
-
resolve: () => buildNetworkSnapshot$
|
|
3262
|
+
resolve: () => buildNetworkSnapshot$b(luvio, config, snapshotRefreshOptions)
|
|
3263
3263
|
});
|
|
3264
3264
|
return cacheSnapshot;
|
|
3265
3265
|
}
|
|
3266
3266
|
const getDataProvidersAdapterFactory = (luvio) => function EinsteinLLM__getDataProviders(untrustedConfig, requestContext) {
|
|
3267
|
-
const config = validateAdapterConfig$
|
|
3267
|
+
const config = validateAdapterConfig$b(untrustedConfig, getDataProviders_ConfigPropertyNames);
|
|
3268
3268
|
// Invalid or incomplete config
|
|
3269
3269
|
if (config === null) {
|
|
3270
3270
|
return null;
|
|
3271
3271
|
}
|
|
3272
3272
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
3273
|
-
buildCachedSnapshotCachePolicy$
|
|
3273
|
+
buildCachedSnapshotCachePolicy$7, buildNetworkSnapshotCachePolicy$7);
|
|
3274
3274
|
};
|
|
3275
3275
|
|
|
3276
|
-
function select$
|
|
3277
|
-
return select$
|
|
3276
|
+
function select$q(luvio, params) {
|
|
3277
|
+
return select$u();
|
|
3278
3278
|
}
|
|
3279
|
-
function keyBuilder$
|
|
3279
|
+
function keyBuilder$e(luvio, params) {
|
|
3280
3280
|
return keyPrefix + '::PromptTemplateDataProviderInstanceConfigRepresentation:(' + stableJSONStringify(params.body.additionalParam) + '::' + 'definition:' + params.body.definition + '::' + 'groupName:' + params.body.groupName + ')';
|
|
3281
3281
|
}
|
|
3282
|
-
function getResponseCacheKeys$
|
|
3283
|
-
getTypeCacheKeys$
|
|
3282
|
+
function getResponseCacheKeys$a(storeKeyMap, luvio, resourceParams, response) {
|
|
3283
|
+
getTypeCacheKeys$5(storeKeyMap, luvio, response, () => keyBuilder$e(luvio, resourceParams));
|
|
3284
3284
|
}
|
|
3285
|
-
function ingestSuccess$
|
|
3285
|
+
function ingestSuccess$a(luvio, resourceParams, response, snapshotRefresh) {
|
|
3286
3286
|
const { body } = response;
|
|
3287
|
-
const key = keyBuilder$
|
|
3288
|
-
luvio.storeIngest(key, ingest$
|
|
3287
|
+
const key = keyBuilder$e(luvio, resourceParams);
|
|
3288
|
+
luvio.storeIngest(key, ingest$5, body);
|
|
3289
3289
|
const snapshot = luvio.storeLookup({
|
|
3290
3290
|
recordId: key,
|
|
3291
|
-
node: select$
|
|
3291
|
+
node: select$q(),
|
|
3292
3292
|
variables: {},
|
|
3293
3293
|
}, snapshotRefresh);
|
|
3294
3294
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -3299,19 +3299,19 @@ function ingestSuccess$9(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
3299
3299
|
deepFreeze(snapshot.data);
|
|
3300
3300
|
return snapshot;
|
|
3301
3301
|
}
|
|
3302
|
-
function ingestError$
|
|
3303
|
-
const key = keyBuilder$
|
|
3302
|
+
function ingestError$6(luvio, params, error, snapshotRefresh) {
|
|
3303
|
+
const key = keyBuilder$e(luvio, params);
|
|
3304
3304
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
3305
3305
|
const storeMetadataParams = {
|
|
3306
|
-
ttl: TTL$
|
|
3306
|
+
ttl: TTL$5,
|
|
3307
3307
|
namespace: keyPrefix,
|
|
3308
|
-
version: VERSION$
|
|
3309
|
-
representationName: RepresentationType$
|
|
3308
|
+
version: VERSION$h,
|
|
3309
|
+
representationName: RepresentationType$5
|
|
3310
3310
|
};
|
|
3311
3311
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
3312
3312
|
return errorSnapshot;
|
|
3313
3313
|
}
|
|
3314
|
-
function createResourceRequest$
|
|
3314
|
+
function createResourceRequest$a(config) {
|
|
3315
3315
|
const headers = {};
|
|
3316
3316
|
return {
|
|
3317
3317
|
baseUri: '/services/data/v65.0',
|
|
@@ -3325,21 +3325,21 @@ function createResourceRequest$9(config) {
|
|
|
3325
3325
|
};
|
|
3326
3326
|
}
|
|
3327
3327
|
|
|
3328
|
-
const adapterName$
|
|
3328
|
+
const adapterName$a = 'getDataProviderInstanceConfig';
|
|
3329
3329
|
const getDataProviderInstanceConfig_ConfigPropertyMetadata = [
|
|
3330
3330
|
generateParamConfigMetadata('additionalParam', false, 2 /* Body */, 4 /* Unsupported */),
|
|
3331
3331
|
generateParamConfigMetadata('definition', true, 2 /* Body */, 0 /* String */),
|
|
3332
3332
|
generateParamConfigMetadata('groupName', true, 2 /* Body */, 0 /* String */),
|
|
3333
3333
|
];
|
|
3334
|
-
const getDataProviderInstanceConfig_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
3335
|
-
const createResourceParams$
|
|
3336
|
-
function keyBuilder$
|
|
3337
|
-
const resourceParams = createResourceParams$
|
|
3338
|
-
return keyBuilder$
|
|
3334
|
+
const getDataProviderInstanceConfig_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$a, getDataProviderInstanceConfig_ConfigPropertyMetadata);
|
|
3335
|
+
const createResourceParams$a = /*#__PURE__*/ createResourceParams$i(getDataProviderInstanceConfig_ConfigPropertyMetadata);
|
|
3336
|
+
function keyBuilder$d(luvio, config) {
|
|
3337
|
+
const resourceParams = createResourceParams$a(config);
|
|
3338
|
+
return keyBuilder$e(luvio, resourceParams);
|
|
3339
3339
|
}
|
|
3340
|
-
function typeCheckConfig$
|
|
3340
|
+
function typeCheckConfig$a(untrustedConfig) {
|
|
3341
3341
|
const config = {};
|
|
3342
|
-
typeCheckConfig$
|
|
3342
|
+
typeCheckConfig$i(untrustedConfig, config, getDataProviderInstanceConfig_ConfigPropertyMetadata);
|
|
3343
3343
|
const untrustedConfig_additionalParam = untrustedConfig.additionalParam;
|
|
3344
3344
|
if (untrustedIsObject(untrustedConfig_additionalParam)) {
|
|
3345
3345
|
const untrustedConfig_additionalParam_object = {};
|
|
@@ -3357,78 +3357,78 @@ function typeCheckConfig$9(untrustedConfig) {
|
|
|
3357
3357
|
}
|
|
3358
3358
|
return config;
|
|
3359
3359
|
}
|
|
3360
|
-
function validateAdapterConfig$
|
|
3360
|
+
function validateAdapterConfig$a(untrustedConfig, configPropertyNames) {
|
|
3361
3361
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
3362
3362
|
return null;
|
|
3363
3363
|
}
|
|
3364
3364
|
if (process.env.NODE_ENV !== 'production') {
|
|
3365
3365
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
3366
3366
|
}
|
|
3367
|
-
const config = typeCheckConfig$
|
|
3367
|
+
const config = typeCheckConfig$a(untrustedConfig);
|
|
3368
3368
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
3369
3369
|
return null;
|
|
3370
3370
|
}
|
|
3371
3371
|
return config;
|
|
3372
3372
|
}
|
|
3373
|
-
function adapterFragment$
|
|
3374
|
-
createResourceParams$
|
|
3375
|
-
return select$
|
|
3373
|
+
function adapterFragment$6(luvio, config) {
|
|
3374
|
+
createResourceParams$a(config);
|
|
3375
|
+
return select$q();
|
|
3376
3376
|
}
|
|
3377
|
-
function onFetchResponseSuccess$
|
|
3378
|
-
const snapshot = ingestSuccess$
|
|
3377
|
+
function onFetchResponseSuccess$6(luvio, config, resourceParams, response) {
|
|
3378
|
+
const snapshot = ingestSuccess$a(luvio, resourceParams, response, {
|
|
3379
3379
|
config,
|
|
3380
|
-
resolve: () => buildNetworkSnapshot$
|
|
3380
|
+
resolve: () => buildNetworkSnapshot$a(luvio, config, snapshotRefreshOptions)
|
|
3381
3381
|
});
|
|
3382
3382
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3383
3383
|
}
|
|
3384
|
-
function onFetchResponseError$
|
|
3385
|
-
const snapshot = ingestError$
|
|
3384
|
+
function onFetchResponseError$6(luvio, config, resourceParams, response) {
|
|
3385
|
+
const snapshot = ingestError$6(luvio, resourceParams, response, {
|
|
3386
3386
|
config,
|
|
3387
|
-
resolve: () => buildNetworkSnapshot$
|
|
3387
|
+
resolve: () => buildNetworkSnapshot$a(luvio, config, snapshotRefreshOptions)
|
|
3388
3388
|
});
|
|
3389
3389
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3390
3390
|
}
|
|
3391
|
-
function buildNetworkSnapshot$
|
|
3392
|
-
const resourceParams = createResourceParams$
|
|
3393
|
-
const request = createResourceRequest$
|
|
3391
|
+
function buildNetworkSnapshot$a(luvio, config, options) {
|
|
3392
|
+
const resourceParams = createResourceParams$a(config);
|
|
3393
|
+
const request = createResourceRequest$a(resourceParams);
|
|
3394
3394
|
return luvio.dispatchResourceRequest(request, options)
|
|
3395
3395
|
.then((response) => {
|
|
3396
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
3396
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$6(luvio, config, resourceParams, response), () => {
|
|
3397
3397
|
const cache = new StoreKeyMap();
|
|
3398
|
-
getResponseCacheKeys$
|
|
3398
|
+
getResponseCacheKeys$a(cache, luvio, resourceParams, response.body);
|
|
3399
3399
|
return cache;
|
|
3400
3400
|
});
|
|
3401
3401
|
}, (response) => {
|
|
3402
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
3402
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$6(luvio, config, resourceParams, response));
|
|
3403
3403
|
});
|
|
3404
3404
|
}
|
|
3405
|
-
function buildNetworkSnapshotCachePolicy$
|
|
3406
|
-
return buildNetworkSnapshotCachePolicy$
|
|
3405
|
+
function buildNetworkSnapshotCachePolicy$6(context, coercedAdapterRequestContext) {
|
|
3406
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$a, 'get', false);
|
|
3407
3407
|
}
|
|
3408
|
-
function buildCachedSnapshotCachePolicy$
|
|
3408
|
+
function buildCachedSnapshotCachePolicy$6(context, storeLookup) {
|
|
3409
3409
|
const { luvio, config } = context;
|
|
3410
3410
|
const selector = {
|
|
3411
|
-
recordId: keyBuilder$
|
|
3412
|
-
node: adapterFragment$
|
|
3411
|
+
recordId: keyBuilder$d(luvio, config),
|
|
3412
|
+
node: adapterFragment$6(luvio, config),
|
|
3413
3413
|
variables: {},
|
|
3414
3414
|
};
|
|
3415
3415
|
const cacheSnapshot = storeLookup(selector, {
|
|
3416
3416
|
config,
|
|
3417
|
-
resolve: () => buildNetworkSnapshot$
|
|
3417
|
+
resolve: () => buildNetworkSnapshot$a(luvio, config, snapshotRefreshOptions)
|
|
3418
3418
|
});
|
|
3419
3419
|
return cacheSnapshot;
|
|
3420
3420
|
}
|
|
3421
3421
|
const getDataProviderInstanceConfigAdapterFactory = (luvio) => function EinsteinLLM__getDataProviderInstanceConfig(untrustedConfig, requestContext) {
|
|
3422
|
-
const config = validateAdapterConfig$
|
|
3422
|
+
const config = validateAdapterConfig$a(untrustedConfig, getDataProviderInstanceConfig_ConfigPropertyNames);
|
|
3423
3423
|
// Invalid or incomplete config
|
|
3424
3424
|
if (config === null) {
|
|
3425
3425
|
return null;
|
|
3426
3426
|
}
|
|
3427
3427
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
3428
|
-
buildCachedSnapshotCachePolicy$
|
|
3428
|
+
buildCachedSnapshotCachePolicy$6, buildNetworkSnapshotCachePolicy$6);
|
|
3429
3429
|
};
|
|
3430
3430
|
|
|
3431
|
-
function validate$
|
|
3431
|
+
function validate$i(obj, path = 'PromptTemplateDataProviderTypeConfigRepresentation') {
|
|
3432
3432
|
const v_error = (() => {
|
|
3433
3433
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
3434
3434
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -3478,9 +3478,9 @@ function validate$f(obj, path = 'PromptTemplateDataProviderTypeConfigRepresentat
|
|
|
3478
3478
|
return v_error === undefined ? null : v_error;
|
|
3479
3479
|
}
|
|
3480
3480
|
|
|
3481
|
-
const TTL$
|
|
3482
|
-
const VERSION$
|
|
3483
|
-
function validate$
|
|
3481
|
+
const TTL$3 = 300;
|
|
3482
|
+
const VERSION$f = "212332dac1decc071b476742df3440fb";
|
|
3483
|
+
function validate$h(obj, path = 'PromptTemplateDataProviderTypeConfigCollectionRepresentation') {
|
|
3484
3484
|
const v_error = (() => {
|
|
3485
3485
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
3486
3486
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -3493,7 +3493,7 @@ function validate$e(obj, path = 'PromptTemplateDataProviderTypeConfigCollectionR
|
|
|
3493
3493
|
for (let i = 0; i < obj_dataProviderTypeConfigs.length; i++) {
|
|
3494
3494
|
const obj_dataProviderTypeConfigs_item = obj_dataProviderTypeConfigs[i];
|
|
3495
3495
|
const path_dataProviderTypeConfigs_item = path_dataProviderTypeConfigs + '[' + i + ']';
|
|
3496
|
-
const referencepath_dataProviderTypeConfigs_itemValidationError = validate$
|
|
3496
|
+
const referencepath_dataProviderTypeConfigs_itemValidationError = validate$i(obj_dataProviderTypeConfigs_item, path_dataProviderTypeConfigs_item);
|
|
3497
3497
|
if (referencepath_dataProviderTypeConfigs_itemValidationError !== null) {
|
|
3498
3498
|
let message = 'Object doesn\'t match PromptTemplateDataProviderTypeConfigRepresentation (at "' + path_dataProviderTypeConfigs_item + '")\n';
|
|
3499
3499
|
message += referencepath_dataProviderTypeConfigs_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -3503,62 +3503,62 @@ function validate$e(obj, path = 'PromptTemplateDataProviderTypeConfigCollectionR
|
|
|
3503
3503
|
})();
|
|
3504
3504
|
return v_error === undefined ? null : v_error;
|
|
3505
3505
|
}
|
|
3506
|
-
const RepresentationType$
|
|
3507
|
-
function normalize$
|
|
3506
|
+
const RepresentationType$3 = 'PromptTemplateDataProviderTypeConfigCollectionRepresentation';
|
|
3507
|
+
function normalize$3(input, existing, path, luvio, store, timestamp) {
|
|
3508
3508
|
return input;
|
|
3509
3509
|
}
|
|
3510
|
-
const select$
|
|
3510
|
+
const select$p = function PromptTemplateDataProviderTypeConfigCollectionRepresentationSelect() {
|
|
3511
3511
|
return {
|
|
3512
3512
|
kind: 'Fragment',
|
|
3513
|
-
version: VERSION$
|
|
3513
|
+
version: VERSION$f,
|
|
3514
3514
|
private: [],
|
|
3515
3515
|
opaque: true
|
|
3516
3516
|
};
|
|
3517
3517
|
};
|
|
3518
|
-
function equals$
|
|
3518
|
+
function equals$f(existing, incoming) {
|
|
3519
3519
|
if (JSONStringify(incoming) !== JSONStringify(existing)) {
|
|
3520
3520
|
return false;
|
|
3521
3521
|
}
|
|
3522
3522
|
return true;
|
|
3523
3523
|
}
|
|
3524
|
-
const ingest$
|
|
3524
|
+
const ingest$3 = function PromptTemplateDataProviderTypeConfigCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
3525
3525
|
if (process.env.NODE_ENV !== 'production') {
|
|
3526
|
-
const validateError = validate$
|
|
3526
|
+
const validateError = validate$h(input);
|
|
3527
3527
|
if (validateError !== null) {
|
|
3528
3528
|
throw validateError;
|
|
3529
3529
|
}
|
|
3530
3530
|
}
|
|
3531
3531
|
const key = path.fullPath;
|
|
3532
|
-
const ttlToUse = TTL$
|
|
3533
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
3532
|
+
const ttlToUse = TTL$3;
|
|
3533
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$3, "EinsteinLLM", VERSION$f, RepresentationType$3, equals$f);
|
|
3534
3534
|
return createLink(key);
|
|
3535
3535
|
};
|
|
3536
|
-
function getTypeCacheKeys$
|
|
3536
|
+
function getTypeCacheKeys$3(rootKeySet, luvio, input, fullPathFactory) {
|
|
3537
3537
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
3538
3538
|
const rootKey = fullPathFactory();
|
|
3539
3539
|
rootKeySet.set(rootKey, {
|
|
3540
3540
|
namespace: keyPrefix,
|
|
3541
|
-
representationName: RepresentationType$
|
|
3541
|
+
representationName: RepresentationType$3,
|
|
3542
3542
|
mergeable: false
|
|
3543
3543
|
});
|
|
3544
3544
|
}
|
|
3545
3545
|
|
|
3546
|
-
function select$
|
|
3547
|
-
return select$
|
|
3546
|
+
function select$o(luvio, params) {
|
|
3547
|
+
return select$p();
|
|
3548
3548
|
}
|
|
3549
|
-
function keyBuilder$
|
|
3549
|
+
function keyBuilder$c(luvio, params) {
|
|
3550
3550
|
return keyPrefix + '::PromptTemplateDataProviderTypeConfigCollectionRepresentation:(' + 'templateType:' + params.urlParams.templateType + ')';
|
|
3551
3551
|
}
|
|
3552
|
-
function getResponseCacheKeys$
|
|
3553
|
-
getTypeCacheKeys$
|
|
3552
|
+
function getResponseCacheKeys$9(storeKeyMap, luvio, resourceParams, response) {
|
|
3553
|
+
getTypeCacheKeys$3(storeKeyMap, luvio, response, () => keyBuilder$c(luvio, resourceParams));
|
|
3554
3554
|
}
|
|
3555
|
-
function ingestSuccess$
|
|
3555
|
+
function ingestSuccess$9(luvio, resourceParams, response, snapshotRefresh) {
|
|
3556
3556
|
const { body } = response;
|
|
3557
|
-
const key = keyBuilder$
|
|
3558
|
-
luvio.storeIngest(key, ingest$
|
|
3557
|
+
const key = keyBuilder$c(luvio, resourceParams);
|
|
3558
|
+
luvio.storeIngest(key, ingest$3, body);
|
|
3559
3559
|
const snapshot = luvio.storeLookup({
|
|
3560
3560
|
recordId: key,
|
|
3561
|
-
node: select$
|
|
3561
|
+
node: select$o(),
|
|
3562
3562
|
variables: {},
|
|
3563
3563
|
}, snapshotRefresh);
|
|
3564
3564
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -3569,19 +3569,19 @@ function ingestSuccess$8(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
3569
3569
|
deepFreeze(snapshot.data);
|
|
3570
3570
|
return snapshot;
|
|
3571
3571
|
}
|
|
3572
|
-
function ingestError$
|
|
3573
|
-
const key = keyBuilder$
|
|
3572
|
+
function ingestError$5(luvio, params, error, snapshotRefresh) {
|
|
3573
|
+
const key = keyBuilder$c(luvio, params);
|
|
3574
3574
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
3575
3575
|
const storeMetadataParams = {
|
|
3576
|
-
ttl: TTL$
|
|
3576
|
+
ttl: TTL$3,
|
|
3577
3577
|
namespace: keyPrefix,
|
|
3578
|
-
version: VERSION$
|
|
3579
|
-
representationName: RepresentationType$
|
|
3578
|
+
version: VERSION$f,
|
|
3579
|
+
representationName: RepresentationType$3
|
|
3580
3580
|
};
|
|
3581
3581
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
3582
3582
|
return errorSnapshot;
|
|
3583
3583
|
}
|
|
3584
|
-
function createResourceRequest$
|
|
3584
|
+
function createResourceRequest$9(config) {
|
|
3585
3585
|
const headers = {};
|
|
3586
3586
|
return {
|
|
3587
3587
|
baseUri: '/services/data/v65.0',
|
|
@@ -3595,108 +3595,108 @@ function createResourceRequest$8(config) {
|
|
|
3595
3595
|
};
|
|
3596
3596
|
}
|
|
3597
3597
|
|
|
3598
|
-
const adapterName$
|
|
3598
|
+
const adapterName$9 = 'getDataProviderTypeConfigs';
|
|
3599
3599
|
const getDataProviderTypeConfigs_ConfigPropertyMetadata = [
|
|
3600
3600
|
generateParamConfigMetadata('templateType', true, 0 /* UrlParameter */, 0 /* String */),
|
|
3601
3601
|
];
|
|
3602
|
-
const getDataProviderTypeConfigs_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
3603
|
-
const createResourceParams$
|
|
3604
|
-
function keyBuilder$
|
|
3605
|
-
const resourceParams = createResourceParams$
|
|
3606
|
-
return keyBuilder$
|
|
3602
|
+
const getDataProviderTypeConfigs_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$9, getDataProviderTypeConfigs_ConfigPropertyMetadata);
|
|
3603
|
+
const createResourceParams$9 = /*#__PURE__*/ createResourceParams$i(getDataProviderTypeConfigs_ConfigPropertyMetadata);
|
|
3604
|
+
function keyBuilder$b(luvio, config) {
|
|
3605
|
+
const resourceParams = createResourceParams$9(config);
|
|
3606
|
+
return keyBuilder$c(luvio, resourceParams);
|
|
3607
3607
|
}
|
|
3608
|
-
function typeCheckConfig$
|
|
3608
|
+
function typeCheckConfig$9(untrustedConfig) {
|
|
3609
3609
|
const config = {};
|
|
3610
|
-
typeCheckConfig$
|
|
3610
|
+
typeCheckConfig$i(untrustedConfig, config, getDataProviderTypeConfigs_ConfigPropertyMetadata);
|
|
3611
3611
|
return config;
|
|
3612
3612
|
}
|
|
3613
|
-
function validateAdapterConfig$
|
|
3613
|
+
function validateAdapterConfig$9(untrustedConfig, configPropertyNames) {
|
|
3614
3614
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
3615
3615
|
return null;
|
|
3616
3616
|
}
|
|
3617
3617
|
if (process.env.NODE_ENV !== 'production') {
|
|
3618
3618
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
3619
3619
|
}
|
|
3620
|
-
const config = typeCheckConfig$
|
|
3620
|
+
const config = typeCheckConfig$9(untrustedConfig);
|
|
3621
3621
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
3622
3622
|
return null;
|
|
3623
3623
|
}
|
|
3624
3624
|
return config;
|
|
3625
3625
|
}
|
|
3626
|
-
function adapterFragment$
|
|
3627
|
-
createResourceParams$
|
|
3628
|
-
return select$
|
|
3626
|
+
function adapterFragment$5(luvio, config) {
|
|
3627
|
+
createResourceParams$9(config);
|
|
3628
|
+
return select$o();
|
|
3629
3629
|
}
|
|
3630
|
-
function onFetchResponseSuccess$
|
|
3631
|
-
const snapshot = ingestSuccess$
|
|
3630
|
+
function onFetchResponseSuccess$5(luvio, config, resourceParams, response) {
|
|
3631
|
+
const snapshot = ingestSuccess$9(luvio, resourceParams, response, {
|
|
3632
3632
|
config,
|
|
3633
|
-
resolve: () => buildNetworkSnapshot$
|
|
3633
|
+
resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
|
|
3634
3634
|
});
|
|
3635
3635
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3636
3636
|
}
|
|
3637
|
-
function onFetchResponseError$
|
|
3638
|
-
const snapshot = ingestError$
|
|
3637
|
+
function onFetchResponseError$5(luvio, config, resourceParams, response) {
|
|
3638
|
+
const snapshot = ingestError$5(luvio, resourceParams, response, {
|
|
3639
3639
|
config,
|
|
3640
|
-
resolve: () => buildNetworkSnapshot$
|
|
3640
|
+
resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
|
|
3641
3641
|
});
|
|
3642
3642
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3643
3643
|
}
|
|
3644
|
-
function buildNetworkSnapshot$
|
|
3645
|
-
const resourceParams = createResourceParams$
|
|
3646
|
-
const request = createResourceRequest$
|
|
3644
|
+
function buildNetworkSnapshot$9(luvio, config, options) {
|
|
3645
|
+
const resourceParams = createResourceParams$9(config);
|
|
3646
|
+
const request = createResourceRequest$9(resourceParams);
|
|
3647
3647
|
return luvio.dispatchResourceRequest(request, options)
|
|
3648
3648
|
.then((response) => {
|
|
3649
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
3649
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$5(luvio, config, resourceParams, response), () => {
|
|
3650
3650
|
const cache = new StoreKeyMap();
|
|
3651
|
-
getResponseCacheKeys$
|
|
3651
|
+
getResponseCacheKeys$9(cache, luvio, resourceParams, response.body);
|
|
3652
3652
|
return cache;
|
|
3653
3653
|
});
|
|
3654
3654
|
}, (response) => {
|
|
3655
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
3655
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$5(luvio, config, resourceParams, response));
|
|
3656
3656
|
});
|
|
3657
3657
|
}
|
|
3658
|
-
function buildNetworkSnapshotCachePolicy$
|
|
3659
|
-
return buildNetworkSnapshotCachePolicy$
|
|
3658
|
+
function buildNetworkSnapshotCachePolicy$5(context, coercedAdapterRequestContext) {
|
|
3659
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$9, undefined, false);
|
|
3660
3660
|
}
|
|
3661
|
-
function buildCachedSnapshotCachePolicy$
|
|
3661
|
+
function buildCachedSnapshotCachePolicy$5(context, storeLookup) {
|
|
3662
3662
|
const { luvio, config } = context;
|
|
3663
3663
|
const selector = {
|
|
3664
|
-
recordId: keyBuilder$
|
|
3665
|
-
node: adapterFragment$
|
|
3664
|
+
recordId: keyBuilder$b(luvio, config),
|
|
3665
|
+
node: adapterFragment$5(luvio, config),
|
|
3666
3666
|
variables: {},
|
|
3667
3667
|
};
|
|
3668
3668
|
const cacheSnapshot = storeLookup(selector, {
|
|
3669
3669
|
config,
|
|
3670
|
-
resolve: () => buildNetworkSnapshot$
|
|
3670
|
+
resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
|
|
3671
3671
|
});
|
|
3672
3672
|
return cacheSnapshot;
|
|
3673
3673
|
}
|
|
3674
3674
|
const getDataProviderTypeConfigsAdapterFactory = (luvio) => function EinsteinLLM__getDataProviderTypeConfigs(untrustedConfig, requestContext) {
|
|
3675
|
-
const config = validateAdapterConfig$
|
|
3675
|
+
const config = validateAdapterConfig$9(untrustedConfig, getDataProviderTypeConfigs_ConfigPropertyNames);
|
|
3676
3676
|
// Invalid or incomplete config
|
|
3677
3677
|
if (config === null) {
|
|
3678
3678
|
return null;
|
|
3679
3679
|
}
|
|
3680
3680
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
3681
|
-
buildCachedSnapshotCachePolicy$
|
|
3681
|
+
buildCachedSnapshotCachePolicy$5, buildNetworkSnapshotCachePolicy$5);
|
|
3682
3682
|
};
|
|
3683
3683
|
|
|
3684
|
-
function select$
|
|
3685
|
-
return select$
|
|
3684
|
+
function select$n(luvio, params) {
|
|
3685
|
+
return select$z();
|
|
3686
3686
|
}
|
|
3687
|
-
function keyBuilder$
|
|
3687
|
+
function keyBuilder$a(luvio, params) {
|
|
3688
3688
|
return keyPrefix + '::EinsteinPromptRecordRepresentation:(' + 'versionId:' + params.queryParams.versionId + ',' + 'promptTemplateDevName:' + params.urlParams.promptTemplateDevName + ')';
|
|
3689
3689
|
}
|
|
3690
|
-
function getResponseCacheKeys$
|
|
3691
|
-
getTypeCacheKeys$
|
|
3690
|
+
function getResponseCacheKeys$8(storeKeyMap, luvio, resourceParams, response) {
|
|
3691
|
+
getTypeCacheKeys$8(storeKeyMap, luvio, response, () => keyBuilder$a(luvio, resourceParams));
|
|
3692
3692
|
}
|
|
3693
|
-
function ingestSuccess$
|
|
3693
|
+
function ingestSuccess$8(luvio, resourceParams, response, snapshotRefresh) {
|
|
3694
3694
|
const { body } = response;
|
|
3695
|
-
const key = keyBuilder$
|
|
3696
|
-
luvio.storeIngest(key, ingest$
|
|
3695
|
+
const key = keyBuilder$a(luvio, resourceParams);
|
|
3696
|
+
luvio.storeIngest(key, ingest$8, body);
|
|
3697
3697
|
const snapshot = luvio.storeLookup({
|
|
3698
3698
|
recordId: key,
|
|
3699
|
-
node: select$
|
|
3699
|
+
node: select$n(),
|
|
3700
3700
|
variables: {},
|
|
3701
3701
|
}, snapshotRefresh);
|
|
3702
3702
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -3707,19 +3707,19 @@ function ingestSuccess$7(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
3707
3707
|
deepFreeze(snapshot.data);
|
|
3708
3708
|
return snapshot;
|
|
3709
3709
|
}
|
|
3710
|
-
function ingestError$
|
|
3711
|
-
const key = keyBuilder$
|
|
3710
|
+
function ingestError$4(luvio, params, error, snapshotRefresh) {
|
|
3711
|
+
const key = keyBuilder$a(luvio, params);
|
|
3712
3712
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
3713
3713
|
const storeMetadataParams = {
|
|
3714
|
-
ttl: TTL$
|
|
3714
|
+
ttl: TTL$8,
|
|
3715
3715
|
namespace: keyPrefix,
|
|
3716
|
-
version: VERSION$
|
|
3717
|
-
representationName: RepresentationType$
|
|
3716
|
+
version: VERSION$k,
|
|
3717
|
+
representationName: RepresentationType$8
|
|
3718
3718
|
};
|
|
3719
3719
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
3720
3720
|
return errorSnapshot;
|
|
3721
3721
|
}
|
|
3722
|
-
function createResourceRequest$
|
|
3722
|
+
function createResourceRequest$8(config) {
|
|
3723
3723
|
const headers = {};
|
|
3724
3724
|
return {
|
|
3725
3725
|
baseUri: '/services/data/v65.0',
|
|
@@ -3733,109 +3733,109 @@ function createResourceRequest$7(config) {
|
|
|
3733
3733
|
};
|
|
3734
3734
|
}
|
|
3735
3735
|
|
|
3736
|
-
const adapterName$
|
|
3736
|
+
const adapterName$8 = 'getPromptTemplate';
|
|
3737
3737
|
const getPromptTemplate_ConfigPropertyMetadata = [
|
|
3738
3738
|
generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
3739
3739
|
generateParamConfigMetadata('versionId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
3740
3740
|
];
|
|
3741
|
-
const getPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
3742
|
-
const createResourceParams$
|
|
3743
|
-
function keyBuilder$
|
|
3744
|
-
const resourceParams = createResourceParams$
|
|
3745
|
-
return keyBuilder$
|
|
3741
|
+
const getPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$8, getPromptTemplate_ConfigPropertyMetadata);
|
|
3742
|
+
const createResourceParams$8 = /*#__PURE__*/ createResourceParams$i(getPromptTemplate_ConfigPropertyMetadata);
|
|
3743
|
+
function keyBuilder$9(luvio, config) {
|
|
3744
|
+
const resourceParams = createResourceParams$8(config);
|
|
3745
|
+
return keyBuilder$a(luvio, resourceParams);
|
|
3746
3746
|
}
|
|
3747
|
-
function typeCheckConfig$
|
|
3747
|
+
function typeCheckConfig$8(untrustedConfig) {
|
|
3748
3748
|
const config = {};
|
|
3749
|
-
typeCheckConfig$
|
|
3749
|
+
typeCheckConfig$i(untrustedConfig, config, getPromptTemplate_ConfigPropertyMetadata);
|
|
3750
3750
|
return config;
|
|
3751
3751
|
}
|
|
3752
|
-
function validateAdapterConfig$
|
|
3752
|
+
function validateAdapterConfig$8(untrustedConfig, configPropertyNames) {
|
|
3753
3753
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
3754
3754
|
return null;
|
|
3755
3755
|
}
|
|
3756
3756
|
if (process.env.NODE_ENV !== 'production') {
|
|
3757
3757
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
3758
3758
|
}
|
|
3759
|
-
const config = typeCheckConfig$
|
|
3759
|
+
const config = typeCheckConfig$8(untrustedConfig);
|
|
3760
3760
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
3761
3761
|
return null;
|
|
3762
3762
|
}
|
|
3763
3763
|
return config;
|
|
3764
3764
|
}
|
|
3765
|
-
function adapterFragment$
|
|
3766
|
-
createResourceParams$
|
|
3767
|
-
return select$
|
|
3765
|
+
function adapterFragment$4(luvio, config) {
|
|
3766
|
+
createResourceParams$8(config);
|
|
3767
|
+
return select$n();
|
|
3768
3768
|
}
|
|
3769
|
-
function onFetchResponseSuccess$
|
|
3770
|
-
const snapshot = ingestSuccess$
|
|
3769
|
+
function onFetchResponseSuccess$4(luvio, config, resourceParams, response) {
|
|
3770
|
+
const snapshot = ingestSuccess$8(luvio, resourceParams, response, {
|
|
3771
3771
|
config,
|
|
3772
|
-
resolve: () => buildNetworkSnapshot$
|
|
3772
|
+
resolve: () => buildNetworkSnapshot$8(luvio, config, snapshotRefreshOptions)
|
|
3773
3773
|
});
|
|
3774
3774
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3775
3775
|
}
|
|
3776
|
-
function onFetchResponseError$
|
|
3777
|
-
const snapshot = ingestError$
|
|
3776
|
+
function onFetchResponseError$4(luvio, config, resourceParams, response) {
|
|
3777
|
+
const snapshot = ingestError$4(luvio, resourceParams, response, {
|
|
3778
3778
|
config,
|
|
3779
|
-
resolve: () => buildNetworkSnapshot$
|
|
3779
|
+
resolve: () => buildNetworkSnapshot$8(luvio, config, snapshotRefreshOptions)
|
|
3780
3780
|
});
|
|
3781
3781
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3782
3782
|
}
|
|
3783
|
-
function buildNetworkSnapshot$
|
|
3784
|
-
const resourceParams = createResourceParams$
|
|
3785
|
-
const request = createResourceRequest$
|
|
3783
|
+
function buildNetworkSnapshot$8(luvio, config, options) {
|
|
3784
|
+
const resourceParams = createResourceParams$8(config);
|
|
3785
|
+
const request = createResourceRequest$8(resourceParams);
|
|
3786
3786
|
return luvio.dispatchResourceRequest(request, options)
|
|
3787
3787
|
.then((response) => {
|
|
3788
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
3788
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$4(luvio, config, resourceParams, response), () => {
|
|
3789
3789
|
const cache = new StoreKeyMap();
|
|
3790
|
-
getResponseCacheKeys$
|
|
3790
|
+
getResponseCacheKeys$8(cache, luvio, resourceParams, response.body);
|
|
3791
3791
|
return cache;
|
|
3792
3792
|
});
|
|
3793
3793
|
}, (response) => {
|
|
3794
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
3794
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$4(luvio, config, resourceParams, response));
|
|
3795
3795
|
});
|
|
3796
3796
|
}
|
|
3797
|
-
function buildNetworkSnapshotCachePolicy$
|
|
3798
|
-
return buildNetworkSnapshotCachePolicy$
|
|
3797
|
+
function buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext) {
|
|
3798
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$8, undefined, false);
|
|
3799
3799
|
}
|
|
3800
|
-
function buildCachedSnapshotCachePolicy$
|
|
3800
|
+
function buildCachedSnapshotCachePolicy$4(context, storeLookup) {
|
|
3801
3801
|
const { luvio, config } = context;
|
|
3802
3802
|
const selector = {
|
|
3803
|
-
recordId: keyBuilder$
|
|
3804
|
-
node: adapterFragment$
|
|
3803
|
+
recordId: keyBuilder$9(luvio, config),
|
|
3804
|
+
node: adapterFragment$4(luvio, config),
|
|
3805
3805
|
variables: {},
|
|
3806
3806
|
};
|
|
3807
3807
|
const cacheSnapshot = storeLookup(selector, {
|
|
3808
3808
|
config,
|
|
3809
|
-
resolve: () => buildNetworkSnapshot$
|
|
3809
|
+
resolve: () => buildNetworkSnapshot$8(luvio, config, snapshotRefreshOptions)
|
|
3810
3810
|
});
|
|
3811
3811
|
return cacheSnapshot;
|
|
3812
3812
|
}
|
|
3813
3813
|
const getPromptTemplateAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplate(untrustedConfig, requestContext) {
|
|
3814
|
-
const config = validateAdapterConfig$
|
|
3814
|
+
const config = validateAdapterConfig$8(untrustedConfig, getPromptTemplate_ConfigPropertyNames);
|
|
3815
3815
|
// Invalid or incomplete config
|
|
3816
3816
|
if (config === null) {
|
|
3817
3817
|
return null;
|
|
3818
3818
|
}
|
|
3819
3819
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
3820
|
-
buildCachedSnapshotCachePolicy$
|
|
3820
|
+
buildCachedSnapshotCachePolicy$4, buildNetworkSnapshotCachePolicy$4);
|
|
3821
3821
|
};
|
|
3822
3822
|
|
|
3823
|
-
function select$
|
|
3824
|
-
return select$
|
|
3823
|
+
function select$m(luvio, params) {
|
|
3824
|
+
return select$z();
|
|
3825
3825
|
}
|
|
3826
|
-
function keyBuilder$
|
|
3826
|
+
function keyBuilder$8(luvio, params) {
|
|
3827
3827
|
return keyPrefix + '::EinsteinPromptRecordRepresentation:(' + 'includingContent:' + params.queryParams.includingContent + ',' + 'includingVersionDetail:' + params.queryParams.includingVersionDetail + ',' + 'promptTemplateDevName:' + params.urlParams.promptTemplateDevName + ')';
|
|
3828
3828
|
}
|
|
3829
|
-
function getResponseCacheKeys$
|
|
3830
|
-
getTypeCacheKeys$
|
|
3829
|
+
function getResponseCacheKeys$7(storeKeyMap, luvio, resourceParams, response) {
|
|
3830
|
+
getTypeCacheKeys$8(storeKeyMap, luvio, response, () => keyBuilder$8(luvio, resourceParams));
|
|
3831
3831
|
}
|
|
3832
|
-
function ingestSuccess$
|
|
3832
|
+
function ingestSuccess$7(luvio, resourceParams, response, snapshotRefresh) {
|
|
3833
3833
|
const { body } = response;
|
|
3834
|
-
const key = keyBuilder$
|
|
3835
|
-
luvio.storeIngest(key, ingest$
|
|
3834
|
+
const key = keyBuilder$8(luvio, resourceParams);
|
|
3835
|
+
luvio.storeIngest(key, ingest$8, body);
|
|
3836
3836
|
const snapshot = luvio.storeLookup({
|
|
3837
3837
|
recordId: key,
|
|
3838
|
-
node: select$
|
|
3838
|
+
node: select$m(),
|
|
3839
3839
|
variables: {},
|
|
3840
3840
|
}, snapshotRefresh);
|
|
3841
3841
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -3846,19 +3846,19 @@ function ingestSuccess$6(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
3846
3846
|
deepFreeze(snapshot.data);
|
|
3847
3847
|
return snapshot;
|
|
3848
3848
|
}
|
|
3849
|
-
function ingestError$
|
|
3850
|
-
const key = keyBuilder$
|
|
3849
|
+
function ingestError$3(luvio, params, error, snapshotRefresh) {
|
|
3850
|
+
const key = keyBuilder$8(luvio, params);
|
|
3851
3851
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
3852
3852
|
const storeMetadataParams = {
|
|
3853
|
-
ttl: TTL$
|
|
3853
|
+
ttl: TTL$8,
|
|
3854
3854
|
namespace: keyPrefix,
|
|
3855
|
-
version: VERSION$
|
|
3856
|
-
representationName: RepresentationType$
|
|
3855
|
+
version: VERSION$k,
|
|
3856
|
+
representationName: RepresentationType$8
|
|
3857
3857
|
};
|
|
3858
3858
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
3859
3859
|
return errorSnapshot;
|
|
3860
3860
|
}
|
|
3861
|
-
function createResourceRequest$
|
|
3861
|
+
function createResourceRequest$7(config) {
|
|
3862
3862
|
const headers = {};
|
|
3863
3863
|
return {
|
|
3864
3864
|
baseUri: '/services/data/v65.0',
|
|
@@ -3872,107 +3872,107 @@ function createResourceRequest$6(config) {
|
|
|
3872
3872
|
};
|
|
3873
3873
|
}
|
|
3874
3874
|
|
|
3875
|
-
const adapterName$
|
|
3875
|
+
const adapterName$7 = 'getPromptTemplateVersions';
|
|
3876
3876
|
const getPromptTemplateVersions_ConfigPropertyMetadata = [
|
|
3877
3877
|
generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
3878
3878
|
generateParamConfigMetadata('includingContent', false, 1 /* QueryParameter */, 1 /* Boolean */),
|
|
3879
3879
|
generateParamConfigMetadata('includingVersionDetail', false, 1 /* QueryParameter */, 1 /* Boolean */),
|
|
3880
3880
|
];
|
|
3881
|
-
const getPromptTemplateVersions_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
3882
|
-
const createResourceParams$
|
|
3883
|
-
function keyBuilder$
|
|
3884
|
-
const resourceParams = createResourceParams$
|
|
3885
|
-
return keyBuilder$
|
|
3881
|
+
const getPromptTemplateVersions_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$7, getPromptTemplateVersions_ConfigPropertyMetadata);
|
|
3882
|
+
const createResourceParams$7 = /*#__PURE__*/ createResourceParams$i(getPromptTemplateVersions_ConfigPropertyMetadata);
|
|
3883
|
+
function keyBuilder$7(luvio, config) {
|
|
3884
|
+
const resourceParams = createResourceParams$7(config);
|
|
3885
|
+
return keyBuilder$8(luvio, resourceParams);
|
|
3886
3886
|
}
|
|
3887
|
-
function typeCheckConfig$
|
|
3887
|
+
function typeCheckConfig$7(untrustedConfig) {
|
|
3888
3888
|
const config = {};
|
|
3889
|
-
typeCheckConfig$
|
|
3889
|
+
typeCheckConfig$i(untrustedConfig, config, getPromptTemplateVersions_ConfigPropertyMetadata);
|
|
3890
3890
|
return config;
|
|
3891
3891
|
}
|
|
3892
|
-
function validateAdapterConfig$
|
|
3892
|
+
function validateAdapterConfig$7(untrustedConfig, configPropertyNames) {
|
|
3893
3893
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
3894
3894
|
return null;
|
|
3895
3895
|
}
|
|
3896
3896
|
if (process.env.NODE_ENV !== 'production') {
|
|
3897
3897
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
3898
3898
|
}
|
|
3899
|
-
const config = typeCheckConfig$
|
|
3899
|
+
const config = typeCheckConfig$7(untrustedConfig);
|
|
3900
3900
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
3901
3901
|
return null;
|
|
3902
3902
|
}
|
|
3903
3903
|
return config;
|
|
3904
3904
|
}
|
|
3905
|
-
function adapterFragment$
|
|
3906
|
-
createResourceParams$
|
|
3907
|
-
return select$
|
|
3905
|
+
function adapterFragment$3(luvio, config) {
|
|
3906
|
+
createResourceParams$7(config);
|
|
3907
|
+
return select$m();
|
|
3908
3908
|
}
|
|
3909
|
-
function onFetchResponseSuccess$
|
|
3910
|
-
const snapshot = ingestSuccess$
|
|
3909
|
+
function onFetchResponseSuccess$3(luvio, config, resourceParams, response) {
|
|
3910
|
+
const snapshot = ingestSuccess$7(luvio, resourceParams, response, {
|
|
3911
3911
|
config,
|
|
3912
|
-
resolve: () => buildNetworkSnapshot$
|
|
3912
|
+
resolve: () => buildNetworkSnapshot$7(luvio, config, snapshotRefreshOptions)
|
|
3913
3913
|
});
|
|
3914
3914
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3915
3915
|
}
|
|
3916
|
-
function onFetchResponseError$
|
|
3917
|
-
const snapshot = ingestError$
|
|
3916
|
+
function onFetchResponseError$3(luvio, config, resourceParams, response) {
|
|
3917
|
+
const snapshot = ingestError$3(luvio, resourceParams, response, {
|
|
3918
3918
|
config,
|
|
3919
|
-
resolve: () => buildNetworkSnapshot$
|
|
3919
|
+
resolve: () => buildNetworkSnapshot$7(luvio, config, snapshotRefreshOptions)
|
|
3920
3920
|
});
|
|
3921
3921
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
3922
3922
|
}
|
|
3923
|
-
function buildNetworkSnapshot$
|
|
3924
|
-
const resourceParams = createResourceParams$
|
|
3925
|
-
const request = createResourceRequest$
|
|
3923
|
+
function buildNetworkSnapshot$7(luvio, config, options) {
|
|
3924
|
+
const resourceParams = createResourceParams$7(config);
|
|
3925
|
+
const request = createResourceRequest$7(resourceParams);
|
|
3926
3926
|
return luvio.dispatchResourceRequest(request, options)
|
|
3927
3927
|
.then((response) => {
|
|
3928
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
3928
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$3(luvio, config, resourceParams, response), () => {
|
|
3929
3929
|
const cache = new StoreKeyMap();
|
|
3930
|
-
getResponseCacheKeys$
|
|
3930
|
+
getResponseCacheKeys$7(cache, luvio, resourceParams, response.body);
|
|
3931
3931
|
return cache;
|
|
3932
3932
|
});
|
|
3933
3933
|
}, (response) => {
|
|
3934
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
3934
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$3(luvio, config, resourceParams, response));
|
|
3935
3935
|
});
|
|
3936
3936
|
}
|
|
3937
|
-
function buildNetworkSnapshotCachePolicy$
|
|
3938
|
-
return buildNetworkSnapshotCachePolicy$
|
|
3937
|
+
function buildNetworkSnapshotCachePolicy$3(context, coercedAdapterRequestContext) {
|
|
3938
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$7, undefined, false);
|
|
3939
3939
|
}
|
|
3940
|
-
function buildCachedSnapshotCachePolicy$
|
|
3940
|
+
function buildCachedSnapshotCachePolicy$3(context, storeLookup) {
|
|
3941
3941
|
const { luvio, config } = context;
|
|
3942
3942
|
const selector = {
|
|
3943
|
-
recordId: keyBuilder$
|
|
3944
|
-
node: adapterFragment$
|
|
3943
|
+
recordId: keyBuilder$7(luvio, config),
|
|
3944
|
+
node: adapterFragment$3(luvio, config),
|
|
3945
3945
|
variables: {},
|
|
3946
3946
|
};
|
|
3947
3947
|
const cacheSnapshot = storeLookup(selector, {
|
|
3948
3948
|
config,
|
|
3949
|
-
resolve: () => buildNetworkSnapshot$
|
|
3949
|
+
resolve: () => buildNetworkSnapshot$7(luvio, config, snapshotRefreshOptions)
|
|
3950
3950
|
});
|
|
3951
3951
|
return cacheSnapshot;
|
|
3952
3952
|
}
|
|
3953
3953
|
const getPromptTemplateVersionsAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplateVersions(untrustedConfig, requestContext) {
|
|
3954
|
-
const config = validateAdapterConfig$
|
|
3954
|
+
const config = validateAdapterConfig$7(untrustedConfig, getPromptTemplateVersions_ConfigPropertyNames);
|
|
3955
3955
|
// Invalid or incomplete config
|
|
3956
3956
|
if (config === null) {
|
|
3957
3957
|
return null;
|
|
3958
3958
|
}
|
|
3959
3959
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
3960
|
-
buildCachedSnapshotCachePolicy$
|
|
3960
|
+
buildCachedSnapshotCachePolicy$3, buildNetworkSnapshotCachePolicy$3);
|
|
3961
3961
|
};
|
|
3962
3962
|
|
|
3963
|
-
function select$
|
|
3964
|
-
return select$
|
|
3963
|
+
function select$l(luvio, params) {
|
|
3964
|
+
return select$w();
|
|
3965
3965
|
}
|
|
3966
|
-
function getResponseCacheKeys$
|
|
3967
|
-
getTypeCacheKeys$
|
|
3966
|
+
function getResponseCacheKeys$6(storeKeyMap, luvio, resourceParams, response) {
|
|
3967
|
+
getTypeCacheKeys$6(storeKeyMap, luvio, response);
|
|
3968
3968
|
}
|
|
3969
|
-
function ingestSuccess$
|
|
3969
|
+
function ingestSuccess$6(luvio, resourceParams, response) {
|
|
3970
3970
|
const { body } = response;
|
|
3971
3971
|
const key = keyBuilderFromType$1(luvio, body);
|
|
3972
|
-
luvio.storeIngest(key, ingest$
|
|
3972
|
+
luvio.storeIngest(key, ingest$6, body);
|
|
3973
3973
|
const snapshot = luvio.storeLookup({
|
|
3974
3974
|
recordId: key,
|
|
3975
|
-
node: select$
|
|
3975
|
+
node: select$l(),
|
|
3976
3976
|
variables: {},
|
|
3977
3977
|
});
|
|
3978
3978
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -3983,7 +3983,7 @@ function ingestSuccess$5(luvio, resourceParams, response) {
|
|
|
3983
3983
|
deepFreeze(snapshot.data);
|
|
3984
3984
|
return snapshot;
|
|
3985
3985
|
}
|
|
3986
|
-
function createResourceRequest$
|
|
3986
|
+
function createResourceRequest$6(config) {
|
|
3987
3987
|
const headers = {};
|
|
3988
3988
|
return {
|
|
3989
3989
|
baseUri: '/services/data/v65.0',
|
|
@@ -3997,7 +3997,7 @@ function createResourceRequest$5(config) {
|
|
|
3997
3997
|
};
|
|
3998
3998
|
}
|
|
3999
3999
|
|
|
4000
|
-
const adapterName$
|
|
4000
|
+
const adapterName$6 = 'createPromptTemplateVersion';
|
|
4001
4001
|
const createPromptTemplateVersion_ConfigPropertyMetadata = [
|
|
4002
4002
|
generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
4003
4003
|
generateParamConfigMetadata('apiName', true, 2 /* Body */, 0 /* String */),
|
|
@@ -4005,11 +4005,11 @@ const createPromptTemplateVersion_ConfigPropertyMetadata = [
|
|
|
4005
4005
|
generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */),
|
|
4006
4006
|
generateParamConfigMetadata('id', false, 2 /* Body */, 0 /* String */),
|
|
4007
4007
|
];
|
|
4008
|
-
const createPromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
4009
|
-
const createResourceParams$
|
|
4010
|
-
function typeCheckConfig$
|
|
4008
|
+
const createPromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$6, createPromptTemplateVersion_ConfigPropertyMetadata);
|
|
4009
|
+
const createResourceParams$6 = /*#__PURE__*/ createResourceParams$i(createPromptTemplateVersion_ConfigPropertyMetadata);
|
|
4010
|
+
function typeCheckConfig$6(untrustedConfig) {
|
|
4011
4011
|
const config = {};
|
|
4012
|
-
typeCheckConfig$
|
|
4012
|
+
typeCheckConfig$i(untrustedConfig, config, createPromptTemplateVersion_ConfigPropertyMetadata);
|
|
4013
4013
|
const untrustedConfig_childRelationships = untrustedConfig.childRelationships;
|
|
4014
4014
|
if (untrustedIsObject(untrustedConfig_childRelationships)) {
|
|
4015
4015
|
const untrustedConfig_childRelationships_object = {};
|
|
@@ -4042,30 +4042,30 @@ function typeCheckConfig$5(untrustedConfig) {
|
|
|
4042
4042
|
}
|
|
4043
4043
|
return config;
|
|
4044
4044
|
}
|
|
4045
|
-
function validateAdapterConfig$
|
|
4045
|
+
function validateAdapterConfig$6(untrustedConfig, configPropertyNames) {
|
|
4046
4046
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
4047
4047
|
return null;
|
|
4048
4048
|
}
|
|
4049
4049
|
if (process.env.NODE_ENV !== 'production') {
|
|
4050
4050
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
4051
4051
|
}
|
|
4052
|
-
const config = typeCheckConfig$
|
|
4052
|
+
const config = typeCheckConfig$6(untrustedConfig);
|
|
4053
4053
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
4054
4054
|
return null;
|
|
4055
4055
|
}
|
|
4056
4056
|
return config;
|
|
4057
4057
|
}
|
|
4058
|
-
function buildNetworkSnapshot$
|
|
4059
|
-
const resourceParams = createResourceParams$
|
|
4060
|
-
const request = createResourceRequest$
|
|
4058
|
+
function buildNetworkSnapshot$6(luvio, config, options) {
|
|
4059
|
+
const resourceParams = createResourceParams$6(config);
|
|
4060
|
+
const request = createResourceRequest$6(resourceParams);
|
|
4061
4061
|
return luvio.dispatchResourceRequest(request, options)
|
|
4062
4062
|
.then((response) => {
|
|
4063
4063
|
return luvio.handleSuccessResponse(() => {
|
|
4064
|
-
const snapshot = ingestSuccess$
|
|
4064
|
+
const snapshot = ingestSuccess$6(luvio, resourceParams, response);
|
|
4065
4065
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
4066
4066
|
}, () => {
|
|
4067
4067
|
const cache = new StoreKeyMap();
|
|
4068
|
-
getResponseCacheKeys$
|
|
4068
|
+
getResponseCacheKeys$6(cache, luvio, resourceParams, response.body);
|
|
4069
4069
|
return cache;
|
|
4070
4070
|
});
|
|
4071
4071
|
}, (response) => {
|
|
@@ -4075,31 +4075,31 @@ function buildNetworkSnapshot$5(luvio, config, options) {
|
|
|
4075
4075
|
}
|
|
4076
4076
|
const createPromptTemplateVersionAdapterFactory = (luvio) => {
|
|
4077
4077
|
return function createPromptTemplateVersion(untrustedConfig) {
|
|
4078
|
-
const config = validateAdapterConfig$
|
|
4078
|
+
const config = validateAdapterConfig$6(untrustedConfig, createPromptTemplateVersion_ConfigPropertyNames);
|
|
4079
4079
|
// Invalid or incomplete config
|
|
4080
4080
|
if (config === null) {
|
|
4081
4081
|
throw new Error('Invalid config for "createPromptTemplateVersion"');
|
|
4082
4082
|
}
|
|
4083
|
-
return buildNetworkSnapshot$
|
|
4083
|
+
return buildNetworkSnapshot$6(luvio, config);
|
|
4084
4084
|
};
|
|
4085
4085
|
};
|
|
4086
4086
|
|
|
4087
|
-
function select$
|
|
4088
|
-
return select$
|
|
4087
|
+
function select$k(luvio, params) {
|
|
4088
|
+
return select$z();
|
|
4089
4089
|
}
|
|
4090
|
-
function keyBuilder$
|
|
4090
|
+
function keyBuilder$6(luvio, params) {
|
|
4091
4091
|
return keyPrefix + '::EinsteinPromptRecordRepresentation:(' + 'includingContent:' + params.queryParams.includingContent + ',' + 'includingVersionDetail:' + params.queryParams.includingVersionDetail + ',' + 'promptTemplateDevName:' + params.urlParams.promptTemplateDevName + ',' + 'versionId:' + params.urlParams.versionId + ')';
|
|
4092
4092
|
}
|
|
4093
|
-
function getResponseCacheKeys$
|
|
4094
|
-
getTypeCacheKeys$
|
|
4093
|
+
function getResponseCacheKeys$5(storeKeyMap, luvio, resourceParams, response) {
|
|
4094
|
+
getTypeCacheKeys$8(storeKeyMap, luvio, response, () => keyBuilder$6(luvio, resourceParams));
|
|
4095
4095
|
}
|
|
4096
|
-
function ingestSuccess$
|
|
4096
|
+
function ingestSuccess$5(luvio, resourceParams, response, snapshotRefresh) {
|
|
4097
4097
|
const { body } = response;
|
|
4098
|
-
const key = keyBuilder$
|
|
4099
|
-
luvio.storeIngest(key, ingest$
|
|
4098
|
+
const key = keyBuilder$6(luvio, resourceParams);
|
|
4099
|
+
luvio.storeIngest(key, ingest$8, body);
|
|
4100
4100
|
const snapshot = luvio.storeLookup({
|
|
4101
4101
|
recordId: key,
|
|
4102
|
-
node: select$
|
|
4102
|
+
node: select$k(),
|
|
4103
4103
|
variables: {},
|
|
4104
4104
|
}, snapshotRefresh);
|
|
4105
4105
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -4110,19 +4110,19 @@ function ingestSuccess$4(luvio, resourceParams, response, snapshotRefresh) {
|
|
|
4110
4110
|
deepFreeze(snapshot.data);
|
|
4111
4111
|
return snapshot;
|
|
4112
4112
|
}
|
|
4113
|
-
function ingestError$
|
|
4114
|
-
const key = keyBuilder$
|
|
4113
|
+
function ingestError$2(luvio, params, error, snapshotRefresh) {
|
|
4114
|
+
const key = keyBuilder$6(luvio, params);
|
|
4115
4115
|
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
4116
4116
|
const storeMetadataParams = {
|
|
4117
|
-
ttl: TTL$
|
|
4117
|
+
ttl: TTL$8,
|
|
4118
4118
|
namespace: keyPrefix,
|
|
4119
|
-
version: VERSION$
|
|
4120
|
-
representationName: RepresentationType$
|
|
4119
|
+
version: VERSION$k,
|
|
4120
|
+
representationName: RepresentationType$8
|
|
4121
4121
|
};
|
|
4122
4122
|
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
4123
4123
|
return errorSnapshot;
|
|
4124
4124
|
}
|
|
4125
|
-
function createResourceRequest$
|
|
4125
|
+
function createResourceRequest$5(config) {
|
|
4126
4126
|
const headers = {};
|
|
4127
4127
|
return {
|
|
4128
4128
|
baseUri: '/services/data/v65.0',
|
|
@@ -4136,108 +4136,108 @@ function createResourceRequest$4(config) {
|
|
|
4136
4136
|
};
|
|
4137
4137
|
}
|
|
4138
4138
|
|
|
4139
|
-
const adapterName$
|
|
4139
|
+
const adapterName$5 = 'getPromptTemplateVersion';
|
|
4140
4140
|
const getPromptTemplateVersion_ConfigPropertyMetadata = [
|
|
4141
4141
|
generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
4142
4142
|
generateParamConfigMetadata('versionId', true, 0 /* UrlParameter */, 0 /* String */),
|
|
4143
4143
|
generateParamConfigMetadata('includingContent', false, 1 /* QueryParameter */, 1 /* Boolean */),
|
|
4144
4144
|
generateParamConfigMetadata('includingVersionDetail', false, 1 /* QueryParameter */, 1 /* Boolean */),
|
|
4145
4145
|
];
|
|
4146
|
-
const getPromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
4147
|
-
const createResourceParams$
|
|
4148
|
-
function keyBuilder$
|
|
4149
|
-
const resourceParams = createResourceParams$
|
|
4150
|
-
return keyBuilder$
|
|
4146
|
+
const getPromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$5, getPromptTemplateVersion_ConfigPropertyMetadata);
|
|
4147
|
+
const createResourceParams$5 = /*#__PURE__*/ createResourceParams$i(getPromptTemplateVersion_ConfigPropertyMetadata);
|
|
4148
|
+
function keyBuilder$5(luvio, config) {
|
|
4149
|
+
const resourceParams = createResourceParams$5(config);
|
|
4150
|
+
return keyBuilder$6(luvio, resourceParams);
|
|
4151
4151
|
}
|
|
4152
|
-
function typeCheckConfig$
|
|
4152
|
+
function typeCheckConfig$5(untrustedConfig) {
|
|
4153
4153
|
const config = {};
|
|
4154
|
-
typeCheckConfig$
|
|
4154
|
+
typeCheckConfig$i(untrustedConfig, config, getPromptTemplateVersion_ConfigPropertyMetadata);
|
|
4155
4155
|
return config;
|
|
4156
4156
|
}
|
|
4157
|
-
function validateAdapterConfig$
|
|
4157
|
+
function validateAdapterConfig$5(untrustedConfig, configPropertyNames) {
|
|
4158
4158
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
4159
4159
|
return null;
|
|
4160
4160
|
}
|
|
4161
4161
|
if (process.env.NODE_ENV !== 'production') {
|
|
4162
4162
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
4163
4163
|
}
|
|
4164
|
-
const config = typeCheckConfig$
|
|
4164
|
+
const config = typeCheckConfig$5(untrustedConfig);
|
|
4165
4165
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
4166
4166
|
return null;
|
|
4167
4167
|
}
|
|
4168
4168
|
return config;
|
|
4169
4169
|
}
|
|
4170
|
-
function adapterFragment$
|
|
4171
|
-
createResourceParams$
|
|
4172
|
-
return select$
|
|
4170
|
+
function adapterFragment$2(luvio, config) {
|
|
4171
|
+
createResourceParams$5(config);
|
|
4172
|
+
return select$k();
|
|
4173
4173
|
}
|
|
4174
|
-
function onFetchResponseSuccess$
|
|
4175
|
-
const snapshot = ingestSuccess$
|
|
4174
|
+
function onFetchResponseSuccess$2(luvio, config, resourceParams, response) {
|
|
4175
|
+
const snapshot = ingestSuccess$5(luvio, resourceParams, response, {
|
|
4176
4176
|
config,
|
|
4177
|
-
resolve: () => buildNetworkSnapshot$
|
|
4177
|
+
resolve: () => buildNetworkSnapshot$5(luvio, config, snapshotRefreshOptions)
|
|
4178
4178
|
});
|
|
4179
4179
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
4180
4180
|
}
|
|
4181
|
-
function onFetchResponseError$
|
|
4182
|
-
const snapshot = ingestError$
|
|
4181
|
+
function onFetchResponseError$2(luvio, config, resourceParams, response) {
|
|
4182
|
+
const snapshot = ingestError$2(luvio, resourceParams, response, {
|
|
4183
4183
|
config,
|
|
4184
|
-
resolve: () => buildNetworkSnapshot$
|
|
4184
|
+
resolve: () => buildNetworkSnapshot$5(luvio, config, snapshotRefreshOptions)
|
|
4185
4185
|
});
|
|
4186
4186
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
4187
4187
|
}
|
|
4188
|
-
function buildNetworkSnapshot$
|
|
4189
|
-
const resourceParams = createResourceParams$
|
|
4190
|
-
const request = createResourceRequest$
|
|
4188
|
+
function buildNetworkSnapshot$5(luvio, config, options) {
|
|
4189
|
+
const resourceParams = createResourceParams$5(config);
|
|
4190
|
+
const request = createResourceRequest$5(resourceParams);
|
|
4191
4191
|
return luvio.dispatchResourceRequest(request, options)
|
|
4192
4192
|
.then((response) => {
|
|
4193
|
-
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$
|
|
4193
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$2(luvio, config, resourceParams, response), () => {
|
|
4194
4194
|
const cache = new StoreKeyMap();
|
|
4195
|
-
getResponseCacheKeys$
|
|
4195
|
+
getResponseCacheKeys$5(cache, luvio, resourceParams, response.body);
|
|
4196
4196
|
return cache;
|
|
4197
4197
|
});
|
|
4198
4198
|
}, (response) => {
|
|
4199
|
-
return luvio.handleErrorResponse(() => onFetchResponseError$
|
|
4199
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$2(luvio, config, resourceParams, response));
|
|
4200
4200
|
});
|
|
4201
4201
|
}
|
|
4202
|
-
function buildNetworkSnapshotCachePolicy$
|
|
4203
|
-
return buildNetworkSnapshotCachePolicy$
|
|
4202
|
+
function buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext) {
|
|
4203
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$5, undefined, false);
|
|
4204
4204
|
}
|
|
4205
|
-
function buildCachedSnapshotCachePolicy$
|
|
4205
|
+
function buildCachedSnapshotCachePolicy$2(context, storeLookup) {
|
|
4206
4206
|
const { luvio, config } = context;
|
|
4207
4207
|
const selector = {
|
|
4208
|
-
recordId: keyBuilder$
|
|
4209
|
-
node: adapterFragment$
|
|
4208
|
+
recordId: keyBuilder$5(luvio, config),
|
|
4209
|
+
node: adapterFragment$2(luvio, config),
|
|
4210
4210
|
variables: {},
|
|
4211
4211
|
};
|
|
4212
4212
|
const cacheSnapshot = storeLookup(selector, {
|
|
4213
4213
|
config,
|
|
4214
|
-
resolve: () => buildNetworkSnapshot$
|
|
4214
|
+
resolve: () => buildNetworkSnapshot$5(luvio, config, snapshotRefreshOptions)
|
|
4215
4215
|
});
|
|
4216
4216
|
return cacheSnapshot;
|
|
4217
4217
|
}
|
|
4218
4218
|
const getPromptTemplateVersionAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplateVersion(untrustedConfig, requestContext) {
|
|
4219
|
-
const config = validateAdapterConfig$
|
|
4219
|
+
const config = validateAdapterConfig$5(untrustedConfig, getPromptTemplateVersion_ConfigPropertyNames);
|
|
4220
4220
|
// Invalid or incomplete config
|
|
4221
4221
|
if (config === null) {
|
|
4222
4222
|
return null;
|
|
4223
4223
|
}
|
|
4224
4224
|
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
4225
|
-
buildCachedSnapshotCachePolicy$
|
|
4225
|
+
buildCachedSnapshotCachePolicy$2, buildNetworkSnapshotCachePolicy$2);
|
|
4226
4226
|
};
|
|
4227
4227
|
|
|
4228
|
-
function select$
|
|
4229
|
-
return select$
|
|
4228
|
+
function select$j(luvio, params) {
|
|
4229
|
+
return select$w();
|
|
4230
4230
|
}
|
|
4231
|
-
function getResponseCacheKeys$
|
|
4232
|
-
getTypeCacheKeys$
|
|
4231
|
+
function getResponseCacheKeys$4(storeKeyMap, luvio, resourceParams, response) {
|
|
4232
|
+
getTypeCacheKeys$6(storeKeyMap, luvio, response);
|
|
4233
4233
|
}
|
|
4234
|
-
function ingestSuccess$
|
|
4234
|
+
function ingestSuccess$4(luvio, resourceParams, response) {
|
|
4235
4235
|
const { body } = response;
|
|
4236
4236
|
const key = keyBuilderFromType$1(luvio, body);
|
|
4237
|
-
luvio.storeIngest(key, ingest$
|
|
4237
|
+
luvio.storeIngest(key, ingest$6, body);
|
|
4238
4238
|
const snapshot = luvio.storeLookup({
|
|
4239
4239
|
recordId: key,
|
|
4240
|
-
node: select$
|
|
4240
|
+
node: select$j(),
|
|
4241
4241
|
variables: {},
|
|
4242
4242
|
});
|
|
4243
4243
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -4248,7 +4248,7 @@ function ingestSuccess$3(luvio, resourceParams, response) {
|
|
|
4248
4248
|
deepFreeze(snapshot.data);
|
|
4249
4249
|
return snapshot;
|
|
4250
4250
|
}
|
|
4251
|
-
function createResourceRequest$
|
|
4251
|
+
function createResourceRequest$4(config) {
|
|
4252
4252
|
const headers = {};
|
|
4253
4253
|
return {
|
|
4254
4254
|
baseUri: '/services/data/v65.0',
|
|
@@ -4262,7 +4262,7 @@ function createResourceRequest$3(config) {
|
|
|
4262
4262
|
};
|
|
4263
4263
|
}
|
|
4264
4264
|
|
|
4265
|
-
const adapterName$
|
|
4265
|
+
const adapterName$4 = 'updatePromptTemplateVersion';
|
|
4266
4266
|
const updatePromptTemplateVersion_ConfigPropertyMetadata = [
|
|
4267
4267
|
generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
4268
4268
|
generateParamConfigMetadata('versionId', true, 0 /* UrlParameter */, 0 /* String */),
|
|
@@ -4271,11 +4271,11 @@ const updatePromptTemplateVersion_ConfigPropertyMetadata = [
|
|
|
4271
4271
|
generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */),
|
|
4272
4272
|
generateParamConfigMetadata('id', false, 2 /* Body */, 0 /* String */),
|
|
4273
4273
|
];
|
|
4274
|
-
const updatePromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
4275
|
-
const createResourceParams$
|
|
4276
|
-
function typeCheckConfig$
|
|
4274
|
+
const updatePromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$4, updatePromptTemplateVersion_ConfigPropertyMetadata);
|
|
4275
|
+
const createResourceParams$4 = /*#__PURE__*/ createResourceParams$i(updatePromptTemplateVersion_ConfigPropertyMetadata);
|
|
4276
|
+
function typeCheckConfig$4(untrustedConfig) {
|
|
4277
4277
|
const config = {};
|
|
4278
|
-
typeCheckConfig$
|
|
4278
|
+
typeCheckConfig$i(untrustedConfig, config, updatePromptTemplateVersion_ConfigPropertyMetadata);
|
|
4279
4279
|
const untrustedConfig_childRelationships = untrustedConfig.childRelationships;
|
|
4280
4280
|
if (untrustedIsObject(untrustedConfig_childRelationships)) {
|
|
4281
4281
|
const untrustedConfig_childRelationships_object = {};
|
|
@@ -4308,30 +4308,30 @@ function typeCheckConfig$3(untrustedConfig) {
|
|
|
4308
4308
|
}
|
|
4309
4309
|
return config;
|
|
4310
4310
|
}
|
|
4311
|
-
function validateAdapterConfig$
|
|
4311
|
+
function validateAdapterConfig$4(untrustedConfig, configPropertyNames) {
|
|
4312
4312
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
4313
4313
|
return null;
|
|
4314
4314
|
}
|
|
4315
4315
|
if (process.env.NODE_ENV !== 'production') {
|
|
4316
4316
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
4317
4317
|
}
|
|
4318
|
-
const config = typeCheckConfig$
|
|
4318
|
+
const config = typeCheckConfig$4(untrustedConfig);
|
|
4319
4319
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
4320
4320
|
return null;
|
|
4321
4321
|
}
|
|
4322
4322
|
return config;
|
|
4323
4323
|
}
|
|
4324
|
-
function buildNetworkSnapshot$
|
|
4325
|
-
const resourceParams = createResourceParams$
|
|
4326
|
-
const request = createResourceRequest$
|
|
4324
|
+
function buildNetworkSnapshot$4(luvio, config, options) {
|
|
4325
|
+
const resourceParams = createResourceParams$4(config);
|
|
4326
|
+
const request = createResourceRequest$4(resourceParams);
|
|
4327
4327
|
return luvio.dispatchResourceRequest(request, options)
|
|
4328
4328
|
.then((response) => {
|
|
4329
4329
|
return luvio.handleSuccessResponse(() => {
|
|
4330
|
-
const snapshot = ingestSuccess$
|
|
4330
|
+
const snapshot = ingestSuccess$4(luvio, resourceParams, response);
|
|
4331
4331
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
4332
4332
|
}, () => {
|
|
4333
4333
|
const cache = new StoreKeyMap();
|
|
4334
|
-
getResponseCacheKeys$
|
|
4334
|
+
getResponseCacheKeys$4(cache, luvio, resourceParams, response.body);
|
|
4335
4335
|
return cache;
|
|
4336
4336
|
});
|
|
4337
4337
|
}, (response) => {
|
|
@@ -4341,28 +4341,28 @@ function buildNetworkSnapshot$3(luvio, config, options) {
|
|
|
4341
4341
|
}
|
|
4342
4342
|
const updatePromptTemplateVersionAdapterFactory = (luvio) => {
|
|
4343
4343
|
return function updatePromptTemplateVersion(untrustedConfig) {
|
|
4344
|
-
const config = validateAdapterConfig$
|
|
4344
|
+
const config = validateAdapterConfig$4(untrustedConfig, updatePromptTemplateVersion_ConfigPropertyNames);
|
|
4345
4345
|
// Invalid or incomplete config
|
|
4346
4346
|
if (config === null) {
|
|
4347
4347
|
throw new Error('Invalid config for "updatePromptTemplateVersion"');
|
|
4348
4348
|
}
|
|
4349
|
-
return buildNetworkSnapshot$
|
|
4349
|
+
return buildNetworkSnapshot$4(luvio, config);
|
|
4350
4350
|
};
|
|
4351
4351
|
};
|
|
4352
4352
|
|
|
4353
|
-
function select$
|
|
4354
|
-
return select$
|
|
4353
|
+
function select$i(luvio, params) {
|
|
4354
|
+
return select$w();
|
|
4355
4355
|
}
|
|
4356
|
-
function getResponseCacheKeys$
|
|
4357
|
-
getTypeCacheKeys$
|
|
4356
|
+
function getResponseCacheKeys$3(storeKeyMap, luvio, resourceParams, response) {
|
|
4357
|
+
getTypeCacheKeys$6(storeKeyMap, luvio, response);
|
|
4358
4358
|
}
|
|
4359
|
-
function ingestSuccess$
|
|
4359
|
+
function ingestSuccess$3(luvio, resourceParams, response) {
|
|
4360
4360
|
const { body } = response;
|
|
4361
4361
|
const key = keyBuilderFromType$1(luvio, body);
|
|
4362
|
-
luvio.storeIngest(key, ingest$
|
|
4362
|
+
luvio.storeIngest(key, ingest$6, body);
|
|
4363
4363
|
const snapshot = luvio.storeLookup({
|
|
4364
4364
|
recordId: key,
|
|
4365
|
-
node: select$
|
|
4365
|
+
node: select$i(),
|
|
4366
4366
|
variables: {},
|
|
4367
4367
|
});
|
|
4368
4368
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -4373,7 +4373,7 @@ function ingestSuccess$2(luvio, resourceParams, response) {
|
|
|
4373
4373
|
deepFreeze(snapshot.data);
|
|
4374
4374
|
return snapshot;
|
|
4375
4375
|
}
|
|
4376
|
-
function createResourceRequest$
|
|
4376
|
+
function createResourceRequest$3(config) {
|
|
4377
4377
|
const headers = {};
|
|
4378
4378
|
return {
|
|
4379
4379
|
baseUri: '/services/data/v65.0',
|
|
@@ -4387,44 +4387,44 @@ function createResourceRequest$2(config) {
|
|
|
4387
4387
|
};
|
|
4388
4388
|
}
|
|
4389
4389
|
|
|
4390
|
-
const adapterName$
|
|
4390
|
+
const adapterName$3 = 'putEinsteinPromptTemplateVersionStatus';
|
|
4391
4391
|
const putEinsteinPromptTemplateVersionStatus_ConfigPropertyMetadata = [
|
|
4392
4392
|
generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
4393
4393
|
generateParamConfigMetadata('versionId', true, 0 /* UrlParameter */, 0 /* String */),
|
|
4394
4394
|
generateParamConfigMetadata('action', false, 1 /* QueryParameter */, 0 /* String */),
|
|
4395
4395
|
generateParamConfigMetadata('ignoreWarnings', false, 1 /* QueryParameter */, 1 /* Boolean */),
|
|
4396
4396
|
];
|
|
4397
|
-
const putEinsteinPromptTemplateVersionStatus_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
4398
|
-
const createResourceParams$
|
|
4399
|
-
function typeCheckConfig$
|
|
4397
|
+
const putEinsteinPromptTemplateVersionStatus_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$3, putEinsteinPromptTemplateVersionStatus_ConfigPropertyMetadata);
|
|
4398
|
+
const createResourceParams$3 = /*#__PURE__*/ createResourceParams$i(putEinsteinPromptTemplateVersionStatus_ConfigPropertyMetadata);
|
|
4399
|
+
function typeCheckConfig$3(untrustedConfig) {
|
|
4400
4400
|
const config = {};
|
|
4401
|
-
typeCheckConfig$
|
|
4401
|
+
typeCheckConfig$i(untrustedConfig, config, putEinsteinPromptTemplateVersionStatus_ConfigPropertyMetadata);
|
|
4402
4402
|
return config;
|
|
4403
4403
|
}
|
|
4404
|
-
function validateAdapterConfig$
|
|
4404
|
+
function validateAdapterConfig$3(untrustedConfig, configPropertyNames) {
|
|
4405
4405
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
4406
4406
|
return null;
|
|
4407
4407
|
}
|
|
4408
4408
|
if (process.env.NODE_ENV !== 'production') {
|
|
4409
4409
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
4410
4410
|
}
|
|
4411
|
-
const config = typeCheckConfig$
|
|
4411
|
+
const config = typeCheckConfig$3(untrustedConfig);
|
|
4412
4412
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
4413
4413
|
return null;
|
|
4414
4414
|
}
|
|
4415
4415
|
return config;
|
|
4416
4416
|
}
|
|
4417
|
-
function buildNetworkSnapshot$
|
|
4418
|
-
const resourceParams = createResourceParams$
|
|
4419
|
-
const request = createResourceRequest$
|
|
4417
|
+
function buildNetworkSnapshot$3(luvio, config, options) {
|
|
4418
|
+
const resourceParams = createResourceParams$3(config);
|
|
4419
|
+
const request = createResourceRequest$3(resourceParams);
|
|
4420
4420
|
return luvio.dispatchResourceRequest(request, options)
|
|
4421
4421
|
.then((response) => {
|
|
4422
4422
|
return luvio.handleSuccessResponse(() => {
|
|
4423
|
-
const snapshot = ingestSuccess$
|
|
4423
|
+
const snapshot = ingestSuccess$3(luvio, resourceParams, response);
|
|
4424
4424
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
4425
4425
|
}, () => {
|
|
4426
4426
|
const cache = new StoreKeyMap();
|
|
4427
|
-
getResponseCacheKeys$
|
|
4427
|
+
getResponseCacheKeys$3(cache, luvio, resourceParams, response.body);
|
|
4428
4428
|
return cache;
|
|
4429
4429
|
});
|
|
4430
4430
|
}, (response) => {
|
|
@@ -4434,16 +4434,16 @@ function buildNetworkSnapshot$2(luvio, config, options) {
|
|
|
4434
4434
|
}
|
|
4435
4435
|
const putEinsteinPromptTemplateVersionStatusAdapterFactory = (luvio) => {
|
|
4436
4436
|
return function putEinsteinPromptTemplateVersionStatus(untrustedConfig) {
|
|
4437
|
-
const config = validateAdapterConfig$
|
|
4437
|
+
const config = validateAdapterConfig$3(untrustedConfig, putEinsteinPromptTemplateVersionStatus_ConfigPropertyNames);
|
|
4438
4438
|
// Invalid or incomplete config
|
|
4439
4439
|
if (config === null) {
|
|
4440
4440
|
throw new Error('Invalid config for "putEinsteinPromptTemplateVersionStatus"');
|
|
4441
4441
|
}
|
|
4442
|
-
return buildNetworkSnapshot$
|
|
4442
|
+
return buildNetworkSnapshot$3(luvio, config);
|
|
4443
4443
|
};
|
|
4444
4444
|
};
|
|
4445
4445
|
|
|
4446
|
-
function validate$
|
|
4446
|
+
function validate$g(obj, path = 'WrappedValueMap') {
|
|
4447
4447
|
const v_error = (() => {
|
|
4448
4448
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
4449
4449
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -4466,7 +4466,7 @@ function validate$d(obj, path = 'WrappedValueMap') {
|
|
|
4466
4466
|
return v_error === undefined ? null : v_error;
|
|
4467
4467
|
}
|
|
4468
4468
|
|
|
4469
|
-
function validate$
|
|
4469
|
+
function validate$f(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresentation') {
|
|
4470
4470
|
const v_error = (() => {
|
|
4471
4471
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
4472
4472
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -4474,7 +4474,7 @@ function validate$c(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresent
|
|
|
4474
4474
|
if (obj.additionalConfig !== undefined) {
|
|
4475
4475
|
const obj_additionalConfig = obj.additionalConfig;
|
|
4476
4476
|
const path_additionalConfig = path + '.additionalConfig';
|
|
4477
|
-
const referencepath_additionalConfigValidationError = validate$
|
|
4477
|
+
const referencepath_additionalConfigValidationError = validate$x(obj_additionalConfig, path_additionalConfig);
|
|
4478
4478
|
if (referencepath_additionalConfigValidationError !== null) {
|
|
4479
4479
|
let message = 'Object doesn\'t match EinsteinLlmAdditionalConfigInputRepresentation (at "' + path_additionalConfig + '")\n';
|
|
4480
4480
|
message += referencepath_additionalConfigValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -4483,7 +4483,7 @@ function validate$c(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresent
|
|
|
4483
4483
|
}
|
|
4484
4484
|
const obj_inputParams = obj.inputParams;
|
|
4485
4485
|
const path_inputParams = path + '.inputParams';
|
|
4486
|
-
const referencepath_inputParamsValidationError = validate$
|
|
4486
|
+
const referencepath_inputParamsValidationError = validate$g(obj_inputParams, path_inputParams);
|
|
4487
4487
|
if (referencepath_inputParamsValidationError !== null) {
|
|
4488
4488
|
let message = 'Object doesn\'t match WrappedValueMap (at "' + path_inputParams + '")\n';
|
|
4489
4489
|
message += referencepath_inputParamsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -4519,8 +4519,8 @@ function validate$c(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresent
|
|
|
4519
4519
|
return v_error === undefined ? null : v_error;
|
|
4520
4520
|
}
|
|
4521
4521
|
|
|
4522
|
-
const VERSION$
|
|
4523
|
-
function validate$
|
|
4522
|
+
const VERSION$e = "63584d83290e21bdff26b1bef3db119c";
|
|
4523
|
+
function validate$e(obj, path = 'EinsteinLlmGenerationGenAiCitedReferenceRepresentation') {
|
|
4524
4524
|
const v_error = (() => {
|
|
4525
4525
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
4526
4526
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -4577,10 +4577,10 @@ function validate$b(obj, path = 'EinsteinLlmGenerationGenAiCitedReferenceReprese
|
|
|
4577
4577
|
})();
|
|
4578
4578
|
return v_error === undefined ? null : v_error;
|
|
4579
4579
|
}
|
|
4580
|
-
const select$
|
|
4580
|
+
const select$h = function EinsteinLlmGenerationGenAiCitedReferenceRepresentationSelect() {
|
|
4581
4581
|
return {
|
|
4582
4582
|
kind: 'Fragment',
|
|
4583
|
-
version: VERSION$
|
|
4583
|
+
version: VERSION$e,
|
|
4584
4584
|
private: [],
|
|
4585
4585
|
selections: [
|
|
4586
4586
|
{
|
|
@@ -4613,7 +4613,7 @@ const select$d = function EinsteinLlmGenerationGenAiCitedReferenceRepresentation
|
|
|
4613
4613
|
]
|
|
4614
4614
|
};
|
|
4615
4615
|
};
|
|
4616
|
-
function equals$
|
|
4616
|
+
function equals$e(existing, incoming) {
|
|
4617
4617
|
const existing_link = existing.link;
|
|
4618
4618
|
const incoming_link = incoming.link;
|
|
4619
4619
|
// if at least one of these optionals is defined
|
|
@@ -4692,8 +4692,8 @@ function equals$b(existing, incoming) {
|
|
|
4692
4692
|
return true;
|
|
4693
4693
|
}
|
|
4694
4694
|
|
|
4695
|
-
const VERSION$
|
|
4696
|
-
function validate$
|
|
4695
|
+
const VERSION$d = "bcc0ea08323732f4187dd2b9f70fea6c";
|
|
4696
|
+
function validate$d(obj, path = 'EinsteinLlmGenerationCitationRepresentation') {
|
|
4697
4697
|
const v_error = (() => {
|
|
4698
4698
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
4699
4699
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -4707,7 +4707,7 @@ function validate$a(obj, path = 'EinsteinLlmGenerationCitationRepresentation') {
|
|
|
4707
4707
|
for (let i = 0; i < obj_citedReferences.length; i++) {
|
|
4708
4708
|
const obj_citedReferences_item = obj_citedReferences[i];
|
|
4709
4709
|
const path_citedReferences_item = path_citedReferences + '[' + i + ']';
|
|
4710
|
-
const referencepath_citedReferences_itemValidationError = validate$
|
|
4710
|
+
const referencepath_citedReferences_itemValidationError = validate$e(obj_citedReferences_item, path_citedReferences_item);
|
|
4711
4711
|
if (referencepath_citedReferences_itemValidationError !== null) {
|
|
4712
4712
|
let message = 'Object doesn\'t match EinsteinLlmGenerationGenAiCitedReferenceRepresentation (at "' + path_citedReferences_item + '")\n';
|
|
4713
4713
|
message += referencepath_citedReferences_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -4718,11 +4718,11 @@ function validate$a(obj, path = 'EinsteinLlmGenerationCitationRepresentation') {
|
|
|
4718
4718
|
})();
|
|
4719
4719
|
return v_error === undefined ? null : v_error;
|
|
4720
4720
|
}
|
|
4721
|
-
const select$
|
|
4722
|
-
const { selections: EinsteinLlmGenerationGenAiCitedReferenceRepresentation__selections, opaque: EinsteinLlmGenerationGenAiCitedReferenceRepresentation__opaque, } = select$
|
|
4721
|
+
const select$g = function EinsteinLlmGenerationCitationRepresentationSelect() {
|
|
4722
|
+
const { selections: EinsteinLlmGenerationGenAiCitedReferenceRepresentation__selections, opaque: EinsteinLlmGenerationGenAiCitedReferenceRepresentation__opaque, } = select$h();
|
|
4723
4723
|
return {
|
|
4724
4724
|
kind: 'Fragment',
|
|
4725
|
-
version: VERSION$
|
|
4725
|
+
version: VERSION$d,
|
|
4726
4726
|
private: [],
|
|
4727
4727
|
selections: [
|
|
4728
4728
|
{
|
|
@@ -4735,7 +4735,7 @@ const select$c = function EinsteinLlmGenerationCitationRepresentationSelect() {
|
|
|
4735
4735
|
]
|
|
4736
4736
|
};
|
|
4737
4737
|
};
|
|
4738
|
-
function equals$
|
|
4738
|
+
function equals$d(existing, incoming) {
|
|
4739
4739
|
const existing_citedReferences = existing.citedReferences;
|
|
4740
4740
|
const incoming_citedReferences = incoming.citedReferences;
|
|
4741
4741
|
// if at least one of these optionals is defined
|
|
@@ -4746,7 +4746,7 @@ function equals$a(existing, incoming) {
|
|
|
4746
4746
|
return false;
|
|
4747
4747
|
}
|
|
4748
4748
|
const equals_citedReferences_items = equalsArray(existing_citedReferences, incoming_citedReferences, (existing_citedReferences_item, incoming_citedReferences_item) => {
|
|
4749
|
-
if (!(equals$
|
|
4749
|
+
if (!(equals$e(existing_citedReferences_item, incoming_citedReferences_item))) {
|
|
4750
4750
|
return false;
|
|
4751
4751
|
}
|
|
4752
4752
|
});
|
|
@@ -4757,8 +4757,8 @@ function equals$a(existing, incoming) {
|
|
|
4757
4757
|
return true;
|
|
4758
4758
|
}
|
|
4759
4759
|
|
|
4760
|
-
const VERSION$
|
|
4761
|
-
function validate$
|
|
4760
|
+
const VERSION$c = "f62ac44b024b123f079b57f349e05230";
|
|
4761
|
+
function validate$c(obj, path = 'EinsteinPromptTemplateAttachmentExclusionInfoRepresentation') {
|
|
4762
4762
|
const v_error = (() => {
|
|
4763
4763
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
4764
4764
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -4776,10 +4776,10 @@ function validate$9(obj, path = 'EinsteinPromptTemplateAttachmentExclusionInfoRe
|
|
|
4776
4776
|
})();
|
|
4777
4777
|
return v_error === undefined ? null : v_error;
|
|
4778
4778
|
}
|
|
4779
|
-
const select$
|
|
4779
|
+
const select$f = function EinsteinPromptTemplateAttachmentExclusionInfoRepresentationSelect() {
|
|
4780
4780
|
return {
|
|
4781
4781
|
kind: 'Fragment',
|
|
4782
|
-
version: VERSION$
|
|
4782
|
+
version: VERSION$c,
|
|
4783
4783
|
private: [],
|
|
4784
4784
|
selections: [
|
|
4785
4785
|
{
|
|
@@ -4793,7 +4793,7 @@ const select$b = function EinsteinPromptTemplateAttachmentExclusionInfoRepresent
|
|
|
4793
4793
|
]
|
|
4794
4794
|
};
|
|
4795
4795
|
};
|
|
4796
|
-
function equals$
|
|
4796
|
+
function equals$c(existing, incoming) {
|
|
4797
4797
|
const existing_isExcluded = existing.isExcluded;
|
|
4798
4798
|
const incoming_isExcluded = incoming.isExcluded;
|
|
4799
4799
|
if (!(existing_isExcluded === incoming_isExcluded)) {
|
|
@@ -4807,8 +4807,8 @@ function equals$9(existing, incoming) {
|
|
|
4807
4807
|
return true;
|
|
4808
4808
|
}
|
|
4809
4809
|
|
|
4810
|
-
const VERSION$
|
|
4811
|
-
function validate$
|
|
4810
|
+
const VERSION$b = "b85a5621c60125d9f1644af130f67680";
|
|
4811
|
+
function validate$b(obj, path = 'EinsteinPromptTemplateAttachmentRepresentation') {
|
|
4812
4812
|
const v_error = (() => {
|
|
4813
4813
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
4814
4814
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -4816,7 +4816,7 @@ function validate$8(obj, path = 'EinsteinPromptTemplateAttachmentRepresentation'
|
|
|
4816
4816
|
if (obj.exclusionInfo !== undefined) {
|
|
4817
4817
|
const obj_exclusionInfo = obj.exclusionInfo;
|
|
4818
4818
|
const path_exclusionInfo = path + '.exclusionInfo';
|
|
4819
|
-
const referencepath_exclusionInfoValidationError = validate$
|
|
4819
|
+
const referencepath_exclusionInfoValidationError = validate$c(obj_exclusionInfo, path_exclusionInfo);
|
|
4820
4820
|
if (referencepath_exclusionInfoValidationError !== null) {
|
|
4821
4821
|
let message = 'Object doesn\'t match EinsteinPromptTemplateAttachmentExclusionInfoRepresentation (at "' + path_exclusionInfo + '")\n';
|
|
4822
4822
|
message += referencepath_exclusionInfoValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -4853,11 +4853,11 @@ function validate$8(obj, path = 'EinsteinPromptTemplateAttachmentRepresentation'
|
|
|
4853
4853
|
})();
|
|
4854
4854
|
return v_error === undefined ? null : v_error;
|
|
4855
4855
|
}
|
|
4856
|
-
const select$
|
|
4857
|
-
const { selections: EinsteinPromptTemplateAttachmentExclusionInfoRepresentation__selections, opaque: EinsteinPromptTemplateAttachmentExclusionInfoRepresentation__opaque, } = select$
|
|
4856
|
+
const select$e = function EinsteinPromptTemplateAttachmentRepresentationSelect() {
|
|
4857
|
+
const { selections: EinsteinPromptTemplateAttachmentExclusionInfoRepresentation__selections, opaque: EinsteinPromptTemplateAttachmentExclusionInfoRepresentation__opaque, } = select$f();
|
|
4858
4858
|
return {
|
|
4859
4859
|
kind: 'Fragment',
|
|
4860
|
-
version: VERSION$
|
|
4860
|
+
version: VERSION$b,
|
|
4861
4861
|
private: [],
|
|
4862
4862
|
selections: [
|
|
4863
4863
|
{
|
|
@@ -4890,7 +4890,7 @@ const select$a = function EinsteinPromptTemplateAttachmentRepresentationSelect()
|
|
|
4890
4890
|
]
|
|
4891
4891
|
};
|
|
4892
4892
|
};
|
|
4893
|
-
function equals$
|
|
4893
|
+
function equals$b(existing, incoming) {
|
|
4894
4894
|
const existing_fileExtension = existing.fileExtension;
|
|
4895
4895
|
const incoming_fileExtension = incoming.fileExtension;
|
|
4896
4896
|
if (!(existing_fileExtension === incoming_fileExtension)) {
|
|
@@ -4933,15 +4933,15 @@ function equals$8(existing, incoming) {
|
|
|
4933
4933
|
if (existing_exclusionInfo === undefined || incoming_exclusionInfo === undefined) {
|
|
4934
4934
|
return false;
|
|
4935
4935
|
}
|
|
4936
|
-
if (!(equals$
|
|
4936
|
+
if (!(equals$c(existing_exclusionInfo, incoming_exclusionInfo))) {
|
|
4937
4937
|
return false;
|
|
4938
4938
|
}
|
|
4939
4939
|
}
|
|
4940
4940
|
return true;
|
|
4941
4941
|
}
|
|
4942
4942
|
|
|
4943
|
-
const VERSION$
|
|
4944
|
-
function validate$
|
|
4943
|
+
const VERSION$a = "6458d624e5a1691821c764b6de0badb3";
|
|
4944
|
+
function validate$a(obj, path = 'EinsteinPromptTemplateGenerationsErrorRepresentation') {
|
|
4945
4945
|
const v_error = (() => {
|
|
4946
4946
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
4947
4947
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -4971,10 +4971,10 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsErrorRepresent
|
|
|
4971
4971
|
})();
|
|
4972
4972
|
return v_error === undefined ? null : v_error;
|
|
4973
4973
|
}
|
|
4974
|
-
const select$
|
|
4974
|
+
const select$d = function EinsteinPromptTemplateGenerationsErrorRepresentationSelect() {
|
|
4975
4975
|
return {
|
|
4976
4976
|
kind: 'Fragment',
|
|
4977
|
-
version: VERSION$
|
|
4977
|
+
version: VERSION$a,
|
|
4978
4978
|
private: [],
|
|
4979
4979
|
selections: [
|
|
4980
4980
|
{
|
|
@@ -4997,7 +4997,7 @@ const select$9 = function EinsteinPromptTemplateGenerationsErrorRepresentationSe
|
|
|
4997
4997
|
]
|
|
4998
4998
|
};
|
|
4999
4999
|
};
|
|
5000
|
-
function equals$
|
|
5000
|
+
function equals$a(existing, incoming) {
|
|
5001
5001
|
const existing_errorMessage = existing.errorMessage;
|
|
5002
5002
|
const incoming_errorMessage = incoming.errorMessage;
|
|
5003
5003
|
if (!(existing_errorMessage === incoming_errorMessage)) {
|
|
@@ -5029,8 +5029,8 @@ function equals$7(existing, incoming) {
|
|
|
5029
5029
|
return true;
|
|
5030
5030
|
}
|
|
5031
5031
|
|
|
5032
|
-
const VERSION$
|
|
5033
|
-
function validate$
|
|
5032
|
+
const VERSION$9 = "7c417ce44e4bc05dfcc454e6825590e8";
|
|
5033
|
+
function validate$9(obj, path = 'EinsteinPromptTemplateMaskSettingsRepresentation') {
|
|
5034
5034
|
const v_error = (() => {
|
|
5035
5035
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5036
5036
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -5043,10 +5043,10 @@ function validate$6(obj, path = 'EinsteinPromptTemplateMaskSettingsRepresentatio
|
|
|
5043
5043
|
})();
|
|
5044
5044
|
return v_error === undefined ? null : v_error;
|
|
5045
5045
|
}
|
|
5046
|
-
const select$
|
|
5046
|
+
const select$c = function EinsteinPromptTemplateMaskSettingsRepresentationSelect() {
|
|
5047
5047
|
return {
|
|
5048
5048
|
kind: 'Fragment',
|
|
5049
|
-
version: VERSION$
|
|
5049
|
+
version: VERSION$9,
|
|
5050
5050
|
private: [],
|
|
5051
5051
|
selections: [
|
|
5052
5052
|
{
|
|
@@ -5056,7 +5056,7 @@ const select$8 = function EinsteinPromptTemplateMaskSettingsRepresentationSelect
|
|
|
5056
5056
|
]
|
|
5057
5057
|
};
|
|
5058
5058
|
};
|
|
5059
|
-
function equals$
|
|
5059
|
+
function equals$9(existing, incoming) {
|
|
5060
5060
|
const existing_enableModeration = existing.enableModeration;
|
|
5061
5061
|
const incoming_enableModeration = incoming.enableModeration;
|
|
5062
5062
|
if (!(existing_enableModeration === incoming_enableModeration)) {
|
|
@@ -5065,8 +5065,8 @@ function equals$6(existing, incoming) {
|
|
|
5065
5065
|
return true;
|
|
5066
5066
|
}
|
|
5067
5067
|
|
|
5068
|
-
const VERSION$
|
|
5069
|
-
function validate$
|
|
5068
|
+
const VERSION$8 = "92ad1abd0e2a60bc36941409cadda7e2";
|
|
5069
|
+
function validate$8(obj, path = 'EinsteinPromptTemplateMaskContentRepresentation') {
|
|
5070
5070
|
const v_error = (() => {
|
|
5071
5071
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5072
5072
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -5081,7 +5081,7 @@ function validate$5(obj, path = 'EinsteinPromptTemplateMaskContentRepresentation
|
|
|
5081
5081
|
const path_moderationSettings = path + '.moderationSettings';
|
|
5082
5082
|
let obj_moderationSettings_union0 = null;
|
|
5083
5083
|
const obj_moderationSettings_union0_error = (() => {
|
|
5084
|
-
const referencepath_moderationSettingsValidationError = validate$
|
|
5084
|
+
const referencepath_moderationSettingsValidationError = validate$9(obj_moderationSettings, path_moderationSettings);
|
|
5085
5085
|
if (referencepath_moderationSettingsValidationError !== null) {
|
|
5086
5086
|
let message = 'Object doesn\'t match EinsteinPromptTemplateMaskSettingsRepresentation (at "' + path_moderationSettings + '")\n';
|
|
5087
5087
|
message += referencepath_moderationSettingsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5117,11 +5117,11 @@ function validate$5(obj, path = 'EinsteinPromptTemplateMaskContentRepresentation
|
|
|
5117
5117
|
})();
|
|
5118
5118
|
return v_error === undefined ? null : v_error;
|
|
5119
5119
|
}
|
|
5120
|
-
const select$
|
|
5121
|
-
const { selections: EinsteinPromptTemplateMaskSettingsRepresentation__selections, opaque: EinsteinPromptTemplateMaskSettingsRepresentation__opaque, } = select$
|
|
5120
|
+
const select$b = function EinsteinPromptTemplateMaskContentRepresentationSelect() {
|
|
5121
|
+
const { selections: EinsteinPromptTemplateMaskSettingsRepresentation__selections, opaque: EinsteinPromptTemplateMaskSettingsRepresentation__opaque, } = select$c();
|
|
5122
5122
|
return {
|
|
5123
5123
|
kind: 'Fragment',
|
|
5124
|
-
version: VERSION$
|
|
5124
|
+
version: VERSION$8,
|
|
5125
5125
|
private: [],
|
|
5126
5126
|
selections: [
|
|
5127
5127
|
{
|
|
@@ -5143,7 +5143,7 @@ const select$7 = function EinsteinPromptTemplateMaskContentRepresentationSelect(
|
|
|
5143
5143
|
]
|
|
5144
5144
|
};
|
|
5145
5145
|
};
|
|
5146
|
-
function equals$
|
|
5146
|
+
function equals$8(existing, incoming) {
|
|
5147
5147
|
const existing_content = existing.content;
|
|
5148
5148
|
const incoming_content = incoming.content;
|
|
5149
5149
|
if (!(existing_content === incoming_content)) {
|
|
@@ -5174,15 +5174,15 @@ function equals$5(existing, incoming) {
|
|
|
5174
5174
|
if (!(existing_moderationSettings === incoming_moderationSettings
|
|
5175
5175
|
|| (existing_moderationSettings != null &&
|
|
5176
5176
|
incoming_moderationSettings != null &&
|
|
5177
|
-
equals$
|
|
5177
|
+
equals$9(existing_moderationSettings, incoming_moderationSettings)))) {
|
|
5178
5178
|
return false;
|
|
5179
5179
|
}
|
|
5180
5180
|
}
|
|
5181
5181
|
return true;
|
|
5182
5182
|
}
|
|
5183
5183
|
|
|
5184
|
-
const VERSION$
|
|
5185
|
-
function validate$
|
|
5184
|
+
const VERSION$7 = "507a815605f8d30ae9b52b0ec513d25e";
|
|
5185
|
+
function validate$7(obj, path = 'EinsteinPromptTemplateMaskDataRepresentation') {
|
|
5186
5186
|
const v_error = (() => {
|
|
5187
5187
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5188
5188
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -5212,10 +5212,10 @@ function validate$4(obj, path = 'EinsteinPromptTemplateMaskDataRepresentation')
|
|
|
5212
5212
|
})();
|
|
5213
5213
|
return v_error === undefined ? null : v_error;
|
|
5214
5214
|
}
|
|
5215
|
-
const select$
|
|
5215
|
+
const select$a = function EinsteinPromptTemplateMaskDataRepresentationSelect() {
|
|
5216
5216
|
return {
|
|
5217
5217
|
kind: 'Fragment',
|
|
5218
|
-
version: VERSION$
|
|
5218
|
+
version: VERSION$7,
|
|
5219
5219
|
private: [],
|
|
5220
5220
|
selections: [
|
|
5221
5221
|
{
|
|
@@ -5234,7 +5234,7 @@ const select$6 = function EinsteinPromptTemplateMaskDataRepresentationSelect() {
|
|
|
5234
5234
|
]
|
|
5235
5235
|
};
|
|
5236
5236
|
};
|
|
5237
|
-
function equals$
|
|
5237
|
+
function equals$7(existing, incoming) {
|
|
5238
5238
|
const existing_originalValue = existing.originalValue;
|
|
5239
5239
|
const incoming_originalValue = incoming.originalValue;
|
|
5240
5240
|
if (!(existing_originalValue === incoming_originalValue)) {
|
|
@@ -5258,9 +5258,9 @@ function equals$4(existing, incoming) {
|
|
|
5258
5258
|
return true;
|
|
5259
5259
|
}
|
|
5260
5260
|
|
|
5261
|
-
const TTL$
|
|
5262
|
-
const VERSION$
|
|
5263
|
-
function validate$
|
|
5261
|
+
const TTL$2 = 100;
|
|
5262
|
+
const VERSION$6 = "4f8799314eebcd45e3fca72dcdf7722d";
|
|
5263
|
+
function validate$6(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation') {
|
|
5264
5264
|
const v_error = (() => {
|
|
5265
5265
|
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5266
5266
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -5268,7 +5268,7 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5268
5268
|
if (obj.citations !== undefined) {
|
|
5269
5269
|
const obj_citations = obj.citations;
|
|
5270
5270
|
const path_citations = path + '.citations';
|
|
5271
|
-
const referencepath_citationsValidationError = validate$
|
|
5271
|
+
const referencepath_citationsValidationError = validate$d(obj_citations, path_citations);
|
|
5272
5272
|
if (referencepath_citationsValidationError !== null) {
|
|
5273
5273
|
let message = 'Object doesn\'t match EinsteinLlmGenerationCitationRepresentation (at "' + path_citations + '")\n';
|
|
5274
5274
|
message += referencepath_citationsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5284,7 +5284,7 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5284
5284
|
for (let i = 0; i < obj_fileData.length; i++) {
|
|
5285
5285
|
const obj_fileData_item = obj_fileData[i];
|
|
5286
5286
|
const path_fileData_item = path_fileData + '[' + i + ']';
|
|
5287
|
-
const referencepath_fileData_itemValidationError = validate$
|
|
5287
|
+
const referencepath_fileData_itemValidationError = validate$b(obj_fileData_item, path_fileData_item);
|
|
5288
5288
|
if (referencepath_fileData_itemValidationError !== null) {
|
|
5289
5289
|
let message = 'Object doesn\'t match EinsteinPromptTemplateAttachmentRepresentation (at "' + path_fileData_item + '")\n';
|
|
5290
5290
|
message += referencepath_fileData_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5301,7 +5301,7 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5301
5301
|
for (let i = 0; i < obj_generationErrors.length; i++) {
|
|
5302
5302
|
const obj_generationErrors_item = obj_generationErrors[i];
|
|
5303
5303
|
const path_generationErrors_item = path_generationErrors + '[' + i + ']';
|
|
5304
|
-
const referencepath_generationErrors_itemValidationError = validate$
|
|
5304
|
+
const referencepath_generationErrors_itemValidationError = validate$a(obj_generationErrors_item, path_generationErrors_item);
|
|
5305
5305
|
if (referencepath_generationErrors_itemValidationError !== null) {
|
|
5306
5306
|
let message = 'Object doesn\'t match EinsteinPromptTemplateGenerationsErrorRepresentation (at "' + path_generationErrors_item + '")\n';
|
|
5307
5307
|
message += referencepath_generationErrors_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5317,7 +5317,7 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5317
5317
|
for (let i = 0; i < obj_generations.length; i++) {
|
|
5318
5318
|
const obj_generations_item = obj_generations[i];
|
|
5319
5319
|
const path_generations_item = path_generations + '[' + i + ']';
|
|
5320
|
-
const referencepath_generations_itemValidationError = validate$
|
|
5320
|
+
const referencepath_generations_itemValidationError = validate$t(obj_generations_item, path_generations_item);
|
|
5321
5321
|
if (referencepath_generations_itemValidationError !== null) {
|
|
5322
5322
|
let message = 'Object doesn\'t match EinsteinLlmGenerationItemRepresentation (at "' + path_generations_item + '")\n';
|
|
5323
5323
|
message += referencepath_generations_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5344,7 +5344,7 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5344
5344
|
const path_parameters = path + '.parameters';
|
|
5345
5345
|
let obj_parameters_union0 = null;
|
|
5346
5346
|
const obj_parameters_union0_error = (() => {
|
|
5347
|
-
const referencepath_parametersValidationError = validate$
|
|
5347
|
+
const referencepath_parametersValidationError = validate$s(obj_parameters, path_parameters);
|
|
5348
5348
|
if (referencepath_parametersValidationError !== null) {
|
|
5349
5349
|
let message = 'Object doesn\'t match WrappedMap (at "' + path_parameters + '")\n';
|
|
5350
5350
|
message += referencepath_parametersValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5440,7 +5440,7 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5440
5440
|
for (let i = 0; i < obj_requestMessages.length; i++) {
|
|
5441
5441
|
const obj_requestMessages_item = obj_requestMessages[i];
|
|
5442
5442
|
const path_requestMessages_item = path_requestMessages + '[' + i + ']';
|
|
5443
|
-
const referencepath_requestMessages_itemValidationError = validate$
|
|
5443
|
+
const referencepath_requestMessages_itemValidationError = validate$8(obj_requestMessages_item, path_requestMessages_item);
|
|
5444
5444
|
if (referencepath_requestMessages_itemValidationError !== null) {
|
|
5445
5445
|
let message = 'Object doesn\'t match EinsteinPromptTemplateMaskContentRepresentation (at "' + path_requestMessages_item + '")\n';
|
|
5446
5446
|
message += referencepath_requestMessages_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5457,7 +5457,7 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5457
5457
|
for (let i = 0; i < obj_responseMessages.length; i++) {
|
|
5458
5458
|
const obj_responseMessages_item = obj_responseMessages[i];
|
|
5459
5459
|
const path_responseMessages_item = path_responseMessages + '[' + i + ']';
|
|
5460
|
-
const referencepath_responseMessages_itemValidationError = validate$
|
|
5460
|
+
const referencepath_responseMessages_itemValidationError = validate$8(obj_responseMessages_item, path_responseMessages_item);
|
|
5461
5461
|
if (referencepath_responseMessages_itemValidationError !== null) {
|
|
5462
5462
|
let message = 'Object doesn\'t match EinsteinPromptTemplateMaskContentRepresentation (at "' + path_responseMessages_item + '")\n';
|
|
5463
5463
|
message += referencepath_responseMessages_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5474,7 +5474,7 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5474
5474
|
for (let i = 0; i < obj_slotsMaskingInformation.length; i++) {
|
|
5475
5475
|
const obj_slotsMaskingInformation_item = obj_slotsMaskingInformation[i];
|
|
5476
5476
|
const path_slotsMaskingInformation_item = path_slotsMaskingInformation + '[' + i + ']';
|
|
5477
|
-
const referencepath_slotsMaskingInformation_itemValidationError = validate$
|
|
5477
|
+
const referencepath_slotsMaskingInformation_itemValidationError = validate$7(obj_slotsMaskingInformation_item, path_slotsMaskingInformation_item);
|
|
5478
5478
|
if (referencepath_slotsMaskingInformation_itemValidationError !== null) {
|
|
5479
5479
|
let message = 'Object doesn\'t match EinsteinPromptTemplateMaskDataRepresentation (at "' + path_slotsMaskingInformation_item + '")\n';
|
|
5480
5480
|
message += referencepath_slotsMaskingInformation_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -5485,30 +5485,30 @@ function validate$3(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
|
|
|
5485
5485
|
})();
|
|
5486
5486
|
return v_error === undefined ? null : v_error;
|
|
5487
5487
|
}
|
|
5488
|
-
const RepresentationType$
|
|
5489
|
-
function keyBuilder$
|
|
5490
|
-
return keyPrefix + '::' + RepresentationType$
|
|
5488
|
+
const RepresentationType$2 = 'EinsteinPromptTemplateGenerationsRepresentation';
|
|
5489
|
+
function keyBuilder$4(luvio, config) {
|
|
5490
|
+
return keyPrefix + '::' + RepresentationType$2 + ':' + config.requestId;
|
|
5491
5491
|
}
|
|
5492
5492
|
function keyBuilderFromType(luvio, object) {
|
|
5493
5493
|
const keyParams = {
|
|
5494
5494
|
requestId: object.requestId
|
|
5495
5495
|
};
|
|
5496
|
-
return keyBuilder$
|
|
5496
|
+
return keyBuilder$4(luvio, keyParams);
|
|
5497
5497
|
}
|
|
5498
|
-
function normalize$
|
|
5498
|
+
function normalize$2(input, existing, path, luvio, store, timestamp) {
|
|
5499
5499
|
return input;
|
|
5500
5500
|
}
|
|
5501
|
-
const select$
|
|
5502
|
-
const { selections: EinsteinLlmGenerationCitationRepresentation__selections, opaque: EinsteinLlmGenerationCitationRepresentation__opaque, } = select$
|
|
5503
|
-
const { selections: EinsteinPromptTemplateAttachmentRepresentation__selections, opaque: EinsteinPromptTemplateAttachmentRepresentation__opaque, } = select$
|
|
5504
|
-
const { selections: EinsteinPromptTemplateGenerationsErrorRepresentation__selections, opaque: EinsteinPromptTemplateGenerationsErrorRepresentation__opaque, } = select$
|
|
5505
|
-
const { selections: EinsteinLlmGenerationItemRepresentation__selections, opaque: EinsteinLlmGenerationItemRepresentation__opaque, } = select$
|
|
5506
|
-
const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$
|
|
5507
|
-
const { selections: EinsteinPromptTemplateMaskContentRepresentation__selections, opaque: EinsteinPromptTemplateMaskContentRepresentation__opaque, } = select$
|
|
5508
|
-
const { selections: EinsteinPromptTemplateMaskDataRepresentation__selections, opaque: EinsteinPromptTemplateMaskDataRepresentation__opaque, } = select$
|
|
5501
|
+
const select$9 = function EinsteinPromptTemplateGenerationsRepresentationSelect() {
|
|
5502
|
+
const { selections: EinsteinLlmGenerationCitationRepresentation__selections, opaque: EinsteinLlmGenerationCitationRepresentation__opaque, } = select$g();
|
|
5503
|
+
const { selections: EinsteinPromptTemplateAttachmentRepresentation__selections, opaque: EinsteinPromptTemplateAttachmentRepresentation__opaque, } = select$e();
|
|
5504
|
+
const { selections: EinsteinPromptTemplateGenerationsErrorRepresentation__selections, opaque: EinsteinPromptTemplateGenerationsErrorRepresentation__opaque, } = select$d();
|
|
5505
|
+
const { selections: EinsteinLlmGenerationItemRepresentation__selections, opaque: EinsteinLlmGenerationItemRepresentation__opaque, } = select$D();
|
|
5506
|
+
const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$C();
|
|
5507
|
+
const { selections: EinsteinPromptTemplateMaskContentRepresentation__selections, opaque: EinsteinPromptTemplateMaskContentRepresentation__opaque, } = select$b();
|
|
5508
|
+
const { selections: EinsteinPromptTemplateMaskDataRepresentation__selections, opaque: EinsteinPromptTemplateMaskDataRepresentation__opaque, } = select$a();
|
|
5509
5509
|
return {
|
|
5510
5510
|
kind: 'Fragment',
|
|
5511
|
-
version: VERSION$
|
|
5511
|
+
version: VERSION$6,
|
|
5512
5512
|
private: [],
|
|
5513
5513
|
selections: [
|
|
5514
5514
|
{
|
|
@@ -5588,7 +5588,7 @@ const select$5 = function EinsteinPromptTemplateGenerationsRepresentationSelect(
|
|
|
5588
5588
|
]
|
|
5589
5589
|
};
|
|
5590
5590
|
};
|
|
5591
|
-
function equals$
|
|
5591
|
+
function equals$6(existing, incoming) {
|
|
5592
5592
|
const existing_promptTemplateDevName = existing.promptTemplateDevName;
|
|
5593
5593
|
const incoming_promptTemplateDevName = incoming.promptTemplateDevName;
|
|
5594
5594
|
if (!(existing_promptTemplateDevName === incoming_promptTemplateDevName)) {
|
|
@@ -5608,7 +5608,7 @@ function equals$3(existing, incoming) {
|
|
|
5608
5608
|
if (existing_citations === undefined || incoming_citations === undefined) {
|
|
5609
5609
|
return false;
|
|
5610
5610
|
}
|
|
5611
|
-
if (!(equals$
|
|
5611
|
+
if (!(equals$d(existing_citations, incoming_citations))) {
|
|
5612
5612
|
return false;
|
|
5613
5613
|
}
|
|
5614
5614
|
}
|
|
@@ -5622,7 +5622,7 @@ function equals$3(existing, incoming) {
|
|
|
5622
5622
|
return false;
|
|
5623
5623
|
}
|
|
5624
5624
|
const equals_fileData_items = equalsArray(existing_fileData, incoming_fileData, (existing_fileData_item, incoming_fileData_item) => {
|
|
5625
|
-
if (!(equals$
|
|
5625
|
+
if (!(equals$b(existing_fileData_item, incoming_fileData_item))) {
|
|
5626
5626
|
return false;
|
|
5627
5627
|
}
|
|
5628
5628
|
});
|
|
@@ -5640,7 +5640,7 @@ function equals$3(existing, incoming) {
|
|
|
5640
5640
|
return false;
|
|
5641
5641
|
}
|
|
5642
5642
|
const equals_generationErrors_items = equalsArray(existing_generationErrors, incoming_generationErrors, (existing_generationErrors_item, incoming_generationErrors_item) => {
|
|
5643
|
-
if (!(equals$
|
|
5643
|
+
if (!(equals$a(existing_generationErrors_item, incoming_generationErrors_item))) {
|
|
5644
5644
|
return false;
|
|
5645
5645
|
}
|
|
5646
5646
|
});
|
|
@@ -5651,7 +5651,7 @@ function equals$3(existing, incoming) {
|
|
|
5651
5651
|
const existing_generations = existing.generations;
|
|
5652
5652
|
const incoming_generations = incoming.generations;
|
|
5653
5653
|
const equals_generations_items = equalsArray(existing_generations, incoming_generations, (existing_generations_item, incoming_generations_item) => {
|
|
5654
|
-
if (!(equals$
|
|
5654
|
+
if (!(equals$n(existing_generations_item, incoming_generations_item))) {
|
|
5655
5655
|
return false;
|
|
5656
5656
|
}
|
|
5657
5657
|
});
|
|
@@ -5681,7 +5681,7 @@ function equals$3(existing, incoming) {
|
|
|
5681
5681
|
if (!(existing_parameters === incoming_parameters
|
|
5682
5682
|
|| (existing_parameters != null &&
|
|
5683
5683
|
incoming_parameters != null &&
|
|
5684
|
-
equals$
|
|
5684
|
+
equals$m(existing_parameters, incoming_parameters)))) {
|
|
5685
5685
|
return false;
|
|
5686
5686
|
}
|
|
5687
5687
|
const existing_prompt = existing.prompt;
|
|
@@ -5704,7 +5704,7 @@ function equals$3(existing, incoming) {
|
|
|
5704
5704
|
return false;
|
|
5705
5705
|
}
|
|
5706
5706
|
const equals_requestMessages_items = equalsArray(existing_requestMessages, incoming_requestMessages, (existing_requestMessages_item, incoming_requestMessages_item) => {
|
|
5707
|
-
if (!(equals$
|
|
5707
|
+
if (!(equals$8(existing_requestMessages_item, incoming_requestMessages_item))) {
|
|
5708
5708
|
return false;
|
|
5709
5709
|
}
|
|
5710
5710
|
});
|
|
@@ -5722,7 +5722,7 @@ function equals$3(existing, incoming) {
|
|
|
5722
5722
|
return false;
|
|
5723
5723
|
}
|
|
5724
5724
|
const equals_responseMessages_items = equalsArray(existing_responseMessages, incoming_responseMessages, (existing_responseMessages_item, incoming_responseMessages_item) => {
|
|
5725
|
-
if (!(equals$
|
|
5725
|
+
if (!(equals$8(existing_responseMessages_item, incoming_responseMessages_item))) {
|
|
5726
5726
|
return false;
|
|
5727
5727
|
}
|
|
5728
5728
|
});
|
|
@@ -5740,7 +5740,7 @@ function equals$3(existing, incoming) {
|
|
|
5740
5740
|
return false;
|
|
5741
5741
|
}
|
|
5742
5742
|
const equals_slotsMaskingInformation_items = equalsArray(existing_slotsMaskingInformation, incoming_slotsMaskingInformation, (existing_slotsMaskingInformation_item, incoming_slotsMaskingInformation_item) => {
|
|
5743
|
-
if (!(equals$
|
|
5743
|
+
if (!(equals$7(existing_slotsMaskingInformation_item, incoming_slotsMaskingInformation_item))) {
|
|
5744
5744
|
return false;
|
|
5745
5745
|
}
|
|
5746
5746
|
});
|
|
@@ -5750,41 +5750,41 @@ function equals$3(existing, incoming) {
|
|
|
5750
5750
|
}
|
|
5751
5751
|
return true;
|
|
5752
5752
|
}
|
|
5753
|
-
const ingest$
|
|
5753
|
+
const ingest$2 = function EinsteinPromptTemplateGenerationsRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
5754
5754
|
if (process.env.NODE_ENV !== 'production') {
|
|
5755
|
-
const validateError = validate$
|
|
5755
|
+
const validateError = validate$6(input);
|
|
5756
5756
|
if (validateError !== null) {
|
|
5757
5757
|
throw validateError;
|
|
5758
5758
|
}
|
|
5759
5759
|
}
|
|
5760
5760
|
const key = keyBuilderFromType(luvio, input);
|
|
5761
|
-
const ttlToUse = TTL$
|
|
5762
|
-
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$
|
|
5761
|
+
const ttlToUse = TTL$2;
|
|
5762
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$2, "EinsteinLLM", VERSION$6, RepresentationType$2, equals$6);
|
|
5763
5763
|
return createLink(key);
|
|
5764
5764
|
};
|
|
5765
|
-
function getTypeCacheKeys$
|
|
5765
|
+
function getTypeCacheKeys$2(rootKeySet, luvio, input, fullPathFactory) {
|
|
5766
5766
|
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
5767
5767
|
const rootKey = keyBuilderFromType(luvio, input);
|
|
5768
5768
|
rootKeySet.set(rootKey, {
|
|
5769
5769
|
namespace: keyPrefix,
|
|
5770
|
-
representationName: RepresentationType$
|
|
5770
|
+
representationName: RepresentationType$2,
|
|
5771
5771
|
mergeable: false
|
|
5772
5772
|
});
|
|
5773
5773
|
}
|
|
5774
5774
|
|
|
5775
|
-
function select$
|
|
5776
|
-
return select$
|
|
5775
|
+
function select$8(luvio, params) {
|
|
5776
|
+
return select$9();
|
|
5777
5777
|
}
|
|
5778
|
-
function getResponseCacheKeys$
|
|
5779
|
-
getTypeCacheKeys$
|
|
5778
|
+
function getResponseCacheKeys$2(storeKeyMap, luvio, resourceParams, response) {
|
|
5779
|
+
getTypeCacheKeys$2(storeKeyMap, luvio, response);
|
|
5780
5780
|
}
|
|
5781
|
-
function ingestSuccess$
|
|
5781
|
+
function ingestSuccess$2(luvio, resourceParams, response) {
|
|
5782
5782
|
const { body } = response;
|
|
5783
5783
|
const key = keyBuilderFromType(luvio, body);
|
|
5784
|
-
luvio.storeIngest(key, ingest$
|
|
5784
|
+
luvio.storeIngest(key, ingest$2, body);
|
|
5785
5785
|
const snapshot = luvio.storeLookup({
|
|
5786
5786
|
recordId: key,
|
|
5787
|
-
node: select$
|
|
5787
|
+
node: select$8(),
|
|
5788
5788
|
variables: {},
|
|
5789
5789
|
});
|
|
5790
5790
|
if (process.env.NODE_ENV !== 'production') {
|
|
@@ -5795,7 +5795,7 @@ function ingestSuccess$1(luvio, resourceParams, response) {
|
|
|
5795
5795
|
deepFreeze(snapshot.data);
|
|
5796
5796
|
return snapshot;
|
|
5797
5797
|
}
|
|
5798
|
-
function createResourceRequest$
|
|
5798
|
+
function createResourceRequest$2(config) {
|
|
5799
5799
|
const headers = {};
|
|
5800
5800
|
return {
|
|
5801
5801
|
baseUri: '/services/data/v65.0',
|
|
@@ -5809,48 +5809,48 @@ function createResourceRequest$1(config) {
|
|
|
5809
5809
|
};
|
|
5810
5810
|
}
|
|
5811
5811
|
|
|
5812
|
-
const adapterName$
|
|
5812
|
+
const adapterName$2 = 'createGenerationsForPromptTemplate';
|
|
5813
5813
|
const createGenerationsForPromptTemplate_ConfigPropertyMetadata = [
|
|
5814
5814
|
generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
5815
5815
|
generateParamConfigMetadata('versionId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
5816
5816
|
generateParamConfigMetadata('promptTemplateGenerationsInput', true, 2 /* Body */, 4 /* Unsupported */),
|
|
5817
5817
|
];
|
|
5818
|
-
const createGenerationsForPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
5819
|
-
const createResourceParams$
|
|
5820
|
-
function typeCheckConfig$
|
|
5818
|
+
const createGenerationsForPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$2, createGenerationsForPromptTemplate_ConfigPropertyMetadata);
|
|
5819
|
+
const createResourceParams$2 = /*#__PURE__*/ createResourceParams$i(createGenerationsForPromptTemplate_ConfigPropertyMetadata);
|
|
5820
|
+
function typeCheckConfig$2(untrustedConfig) {
|
|
5821
5821
|
const config = {};
|
|
5822
|
-
typeCheckConfig$
|
|
5822
|
+
typeCheckConfig$i(untrustedConfig, config, createGenerationsForPromptTemplate_ConfigPropertyMetadata);
|
|
5823
5823
|
const untrustedConfig_promptTemplateGenerationsInput = untrustedConfig.promptTemplateGenerationsInput;
|
|
5824
|
-
const referenceEinsteinPromptTemplateGenerationsInputRepresentationValidationError = validate$
|
|
5824
|
+
const referenceEinsteinPromptTemplateGenerationsInputRepresentationValidationError = validate$f(untrustedConfig_promptTemplateGenerationsInput);
|
|
5825
5825
|
if (referenceEinsteinPromptTemplateGenerationsInputRepresentationValidationError === null) {
|
|
5826
5826
|
config.promptTemplateGenerationsInput = untrustedConfig_promptTemplateGenerationsInput;
|
|
5827
5827
|
}
|
|
5828
5828
|
return config;
|
|
5829
5829
|
}
|
|
5830
|
-
function validateAdapterConfig$
|
|
5830
|
+
function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
|
|
5831
5831
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
5832
5832
|
return null;
|
|
5833
5833
|
}
|
|
5834
5834
|
if (process.env.NODE_ENV !== 'production') {
|
|
5835
5835
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
5836
5836
|
}
|
|
5837
|
-
const config = typeCheckConfig$
|
|
5837
|
+
const config = typeCheckConfig$2(untrustedConfig);
|
|
5838
5838
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
5839
5839
|
return null;
|
|
5840
5840
|
}
|
|
5841
5841
|
return config;
|
|
5842
5842
|
}
|
|
5843
|
-
function buildNetworkSnapshot$
|
|
5844
|
-
const resourceParams = createResourceParams$
|
|
5845
|
-
const request = createResourceRequest$
|
|
5843
|
+
function buildNetworkSnapshot$2(luvio, config, options) {
|
|
5844
|
+
const resourceParams = createResourceParams$2(config);
|
|
5845
|
+
const request = createResourceRequest$2(resourceParams);
|
|
5846
5846
|
return luvio.dispatchResourceRequest(request, options)
|
|
5847
5847
|
.then((response) => {
|
|
5848
5848
|
return luvio.handleSuccessResponse(() => {
|
|
5849
|
-
const snapshot = ingestSuccess$
|
|
5849
|
+
const snapshot = ingestSuccess$2(luvio, resourceParams, response);
|
|
5850
5850
|
return luvio.storeBroadcast().then(() => snapshot);
|
|
5851
5851
|
}, () => {
|
|
5852
5852
|
const cache = new StoreKeyMap();
|
|
5853
|
-
getResponseCacheKeys$
|
|
5853
|
+
getResponseCacheKeys$2(cache, luvio, resourceParams, response.body);
|
|
5854
5854
|
return cache;
|
|
5855
5855
|
});
|
|
5856
5856
|
}, (response) => {
|
|
@@ -5860,14 +5860,464 @@ function buildNetworkSnapshot$1(luvio, config, options) {
|
|
|
5860
5860
|
}
|
|
5861
5861
|
const createGenerationsForPromptTemplateAdapterFactory = (luvio) => {
|
|
5862
5862
|
return function createGenerationsForPromptTemplate(untrustedConfig) {
|
|
5863
|
-
const config = validateAdapterConfig$
|
|
5863
|
+
const config = validateAdapterConfig$2(untrustedConfig, createGenerationsForPromptTemplate_ConfigPropertyNames);
|
|
5864
5864
|
// Invalid or incomplete config
|
|
5865
5865
|
if (config === null) {
|
|
5866
5866
|
throw new Error('Invalid config for "createGenerationsForPromptTemplate"');
|
|
5867
5867
|
}
|
|
5868
|
-
return buildNetworkSnapshot$
|
|
5868
|
+
return buildNetworkSnapshot$2(luvio, config);
|
|
5869
|
+
};
|
|
5870
|
+
};
|
|
5871
|
+
|
|
5872
|
+
const VERSION$5 = "f08355bdc491f090c787309a8a476caa";
|
|
5873
|
+
function validate$5(obj, path = 'EinsteinPromptTypeSchemaInputFieldRepresentation') {
|
|
5874
|
+
const v_error = (() => {
|
|
5875
|
+
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5876
|
+
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
5877
|
+
}
|
|
5878
|
+
const obj_apiName = obj.apiName;
|
|
5879
|
+
const path_apiName = path + '.apiName';
|
|
5880
|
+
if (typeof obj_apiName !== 'string') {
|
|
5881
|
+
return new TypeError('Expected "string" but received "' + typeof obj_apiName + '" (at "' + path_apiName + '")');
|
|
5882
|
+
}
|
|
5883
|
+
if (obj.label !== undefined) {
|
|
5884
|
+
const obj_label = obj.label;
|
|
5885
|
+
const path_label = path + '.label';
|
|
5886
|
+
if (typeof obj_label !== 'string') {
|
|
5887
|
+
return new TypeError('Expected "string" but received "' + typeof obj_label + '" (at "' + path_label + '")');
|
|
5888
|
+
}
|
|
5889
|
+
}
|
|
5890
|
+
if (obj.referenceName !== undefined) {
|
|
5891
|
+
const obj_referenceName = obj.referenceName;
|
|
5892
|
+
const path_referenceName = path + '.referenceName';
|
|
5893
|
+
if (typeof obj_referenceName !== 'string') {
|
|
5894
|
+
return new TypeError('Expected "string" but received "' + typeof obj_referenceName + '" (at "' + path_referenceName + '")');
|
|
5895
|
+
}
|
|
5896
|
+
}
|
|
5897
|
+
if (obj.typeDefinition !== undefined) {
|
|
5898
|
+
const obj_typeDefinition = obj.typeDefinition;
|
|
5899
|
+
const path_typeDefinition = path + '.typeDefinition';
|
|
5900
|
+
if (typeof obj_typeDefinition !== 'string') {
|
|
5901
|
+
return new TypeError('Expected "string" but received "' + typeof obj_typeDefinition + '" (at "' + path_typeDefinition + '")');
|
|
5902
|
+
}
|
|
5903
|
+
}
|
|
5904
|
+
})();
|
|
5905
|
+
return v_error === undefined ? null : v_error;
|
|
5906
|
+
}
|
|
5907
|
+
const select$7 = function EinsteinPromptTypeSchemaInputFieldRepresentationSelect() {
|
|
5908
|
+
return {
|
|
5909
|
+
kind: 'Fragment',
|
|
5910
|
+
version: VERSION$5,
|
|
5911
|
+
private: [],
|
|
5912
|
+
selections: [
|
|
5913
|
+
{
|
|
5914
|
+
name: 'apiName',
|
|
5915
|
+
kind: 'Scalar'
|
|
5916
|
+
},
|
|
5917
|
+
{
|
|
5918
|
+
name: 'label',
|
|
5919
|
+
kind: 'Scalar',
|
|
5920
|
+
required: false
|
|
5921
|
+
},
|
|
5922
|
+
{
|
|
5923
|
+
name: 'referenceName',
|
|
5924
|
+
kind: 'Scalar',
|
|
5925
|
+
required: false
|
|
5926
|
+
},
|
|
5927
|
+
{
|
|
5928
|
+
name: 'typeDefinition',
|
|
5929
|
+
kind: 'Scalar',
|
|
5930
|
+
required: false
|
|
5931
|
+
}
|
|
5932
|
+
]
|
|
5933
|
+
};
|
|
5934
|
+
};
|
|
5935
|
+
function equals$5(existing, incoming) {
|
|
5936
|
+
const existing_apiName = existing.apiName;
|
|
5937
|
+
const incoming_apiName = incoming.apiName;
|
|
5938
|
+
if (!(existing_apiName === incoming_apiName)) {
|
|
5939
|
+
return false;
|
|
5940
|
+
}
|
|
5941
|
+
const existing_label = existing.label;
|
|
5942
|
+
const incoming_label = incoming.label;
|
|
5943
|
+
// if at least one of these optionals is defined
|
|
5944
|
+
if (existing_label !== undefined || incoming_label !== undefined) {
|
|
5945
|
+
// if one of these is not defined we know the other is defined and therefore
|
|
5946
|
+
// not equal
|
|
5947
|
+
if (existing_label === undefined || incoming_label === undefined) {
|
|
5948
|
+
return false;
|
|
5949
|
+
}
|
|
5950
|
+
if (!(existing_label === incoming_label)) {
|
|
5951
|
+
return false;
|
|
5952
|
+
}
|
|
5953
|
+
}
|
|
5954
|
+
const existing_referenceName = existing.referenceName;
|
|
5955
|
+
const incoming_referenceName = incoming.referenceName;
|
|
5956
|
+
// if at least one of these optionals is defined
|
|
5957
|
+
if (existing_referenceName !== undefined || incoming_referenceName !== undefined) {
|
|
5958
|
+
// if one of these is not defined we know the other is defined and therefore
|
|
5959
|
+
// not equal
|
|
5960
|
+
if (existing_referenceName === undefined || incoming_referenceName === undefined) {
|
|
5961
|
+
return false;
|
|
5962
|
+
}
|
|
5963
|
+
if (!(existing_referenceName === incoming_referenceName)) {
|
|
5964
|
+
return false;
|
|
5965
|
+
}
|
|
5966
|
+
}
|
|
5967
|
+
const existing_typeDefinition = existing.typeDefinition;
|
|
5968
|
+
const incoming_typeDefinition = incoming.typeDefinition;
|
|
5969
|
+
// if at least one of these optionals is defined
|
|
5970
|
+
if (existing_typeDefinition !== undefined || incoming_typeDefinition !== undefined) {
|
|
5971
|
+
// if one of these is not defined we know the other is defined and therefore
|
|
5972
|
+
// not equal
|
|
5973
|
+
if (existing_typeDefinition === undefined || incoming_typeDefinition === undefined) {
|
|
5974
|
+
return false;
|
|
5975
|
+
}
|
|
5976
|
+
if (!(existing_typeDefinition === incoming_typeDefinition)) {
|
|
5977
|
+
return false;
|
|
5978
|
+
}
|
|
5979
|
+
}
|
|
5980
|
+
return true;
|
|
5981
|
+
}
|
|
5982
|
+
|
|
5983
|
+
const VERSION$4 = "a0cab6d022a5571ceb94328166f1db95";
|
|
5984
|
+
function validate$4(obj, path = 'EinsteinPromptTypeSchemaRepresentation') {
|
|
5985
|
+
const v_error = (() => {
|
|
5986
|
+
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
5987
|
+
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
5988
|
+
}
|
|
5989
|
+
const obj_allowInputExtension = obj.allowInputExtension;
|
|
5990
|
+
const path_allowInputExtension = path + '.allowInputExtension';
|
|
5991
|
+
if (typeof obj_allowInputExtension !== 'boolean') {
|
|
5992
|
+
return new TypeError('Expected "boolean" but received "' + typeof obj_allowInputExtension + '" (at "' + path_allowInputExtension + '")');
|
|
5993
|
+
}
|
|
5994
|
+
const obj_inputs = obj.inputs;
|
|
5995
|
+
const path_inputs = path + '.inputs';
|
|
5996
|
+
if (!ArrayIsArray(obj_inputs)) {
|
|
5997
|
+
return new TypeError('Expected "array" but received "' + typeof obj_inputs + '" (at "' + path_inputs + '")');
|
|
5998
|
+
}
|
|
5999
|
+
for (let i = 0; i < obj_inputs.length; i++) {
|
|
6000
|
+
const obj_inputs_item = obj_inputs[i];
|
|
6001
|
+
const path_inputs_item = path_inputs + '[' + i + ']';
|
|
6002
|
+
const referencepath_inputs_itemValidationError = validate$5(obj_inputs_item, path_inputs_item);
|
|
6003
|
+
if (referencepath_inputs_itemValidationError !== null) {
|
|
6004
|
+
let message = 'Object doesn\'t match EinsteinPromptTypeSchemaInputFieldRepresentation (at "' + path_inputs_item + '")\n';
|
|
6005
|
+
message += referencepath_inputs_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
6006
|
+
return new TypeError(message);
|
|
6007
|
+
}
|
|
6008
|
+
}
|
|
6009
|
+
if (obj.primaryObjectId !== undefined) {
|
|
6010
|
+
const obj_primaryObjectId = obj.primaryObjectId;
|
|
6011
|
+
const path_primaryObjectId = path + '.primaryObjectId';
|
|
6012
|
+
if (typeof obj_primaryObjectId !== 'string') {
|
|
6013
|
+
return new TypeError('Expected "string" but received "' + typeof obj_primaryObjectId + '" (at "' + path_primaryObjectId + '")');
|
|
6014
|
+
}
|
|
6015
|
+
}
|
|
6016
|
+
})();
|
|
6017
|
+
return v_error === undefined ? null : v_error;
|
|
6018
|
+
}
|
|
6019
|
+
const select$6 = function EinsteinPromptTypeSchemaRepresentationSelect() {
|
|
6020
|
+
const { selections: EinsteinPromptTypeSchemaInputFieldRepresentation__selections, opaque: EinsteinPromptTypeSchemaInputFieldRepresentation__opaque, } = select$7();
|
|
6021
|
+
return {
|
|
6022
|
+
kind: 'Fragment',
|
|
6023
|
+
version: VERSION$4,
|
|
6024
|
+
private: [],
|
|
6025
|
+
selections: [
|
|
6026
|
+
{
|
|
6027
|
+
name: 'allowInputExtension',
|
|
6028
|
+
kind: 'Scalar'
|
|
6029
|
+
},
|
|
6030
|
+
{
|
|
6031
|
+
name: 'inputs',
|
|
6032
|
+
kind: 'Object',
|
|
6033
|
+
plural: true,
|
|
6034
|
+
selections: EinsteinPromptTypeSchemaInputFieldRepresentation__selections
|
|
6035
|
+
},
|
|
6036
|
+
{
|
|
6037
|
+
name: 'primaryObjectId',
|
|
6038
|
+
kind: 'Scalar',
|
|
6039
|
+
required: false
|
|
6040
|
+
}
|
|
6041
|
+
]
|
|
5869
6042
|
};
|
|
5870
6043
|
};
|
|
6044
|
+
function equals$4(existing, incoming) {
|
|
6045
|
+
const existing_allowInputExtension = existing.allowInputExtension;
|
|
6046
|
+
const incoming_allowInputExtension = incoming.allowInputExtension;
|
|
6047
|
+
if (!(existing_allowInputExtension === incoming_allowInputExtension)) {
|
|
6048
|
+
return false;
|
|
6049
|
+
}
|
|
6050
|
+
const existing_primaryObjectId = existing.primaryObjectId;
|
|
6051
|
+
const incoming_primaryObjectId = incoming.primaryObjectId;
|
|
6052
|
+
// if at least one of these optionals is defined
|
|
6053
|
+
if (existing_primaryObjectId !== undefined || incoming_primaryObjectId !== undefined) {
|
|
6054
|
+
// if one of these is not defined we know the other is defined and therefore
|
|
6055
|
+
// not equal
|
|
6056
|
+
if (existing_primaryObjectId === undefined || incoming_primaryObjectId === undefined) {
|
|
6057
|
+
return false;
|
|
6058
|
+
}
|
|
6059
|
+
if (!(existing_primaryObjectId === incoming_primaryObjectId)) {
|
|
6060
|
+
return false;
|
|
6061
|
+
}
|
|
6062
|
+
}
|
|
6063
|
+
const existing_inputs = existing.inputs;
|
|
6064
|
+
const incoming_inputs = incoming.inputs;
|
|
6065
|
+
const equals_inputs_items = equalsArray(existing_inputs, incoming_inputs, (existing_inputs_item, incoming_inputs_item) => {
|
|
6066
|
+
if (!(equals$5(existing_inputs_item, incoming_inputs_item))) {
|
|
6067
|
+
return false;
|
|
6068
|
+
}
|
|
6069
|
+
});
|
|
6070
|
+
if (equals_inputs_items === false) {
|
|
6071
|
+
return false;
|
|
6072
|
+
}
|
|
6073
|
+
return true;
|
|
6074
|
+
}
|
|
6075
|
+
|
|
6076
|
+
const TTL$1 = 300;
|
|
6077
|
+
const VERSION$3 = "bb627c12e7041da02926d6b2affc98a1";
|
|
6078
|
+
function validate$3(obj, path = 'EinsteinPromptTypeRecordRepresentation') {
|
|
6079
|
+
const v_error = (() => {
|
|
6080
|
+
if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
|
|
6081
|
+
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
6082
|
+
}
|
|
6083
|
+
const obj_excludedGlobalVariables = obj.excludedGlobalVariables;
|
|
6084
|
+
const path_excludedGlobalVariables = path + '.excludedGlobalVariables';
|
|
6085
|
+
if (!ArrayIsArray(obj_excludedGlobalVariables)) {
|
|
6086
|
+
return new TypeError('Expected "array" but received "' + typeof obj_excludedGlobalVariables + '" (at "' + path_excludedGlobalVariables + '")');
|
|
6087
|
+
}
|
|
6088
|
+
for (let i = 0; i < obj_excludedGlobalVariables.length; i++) {
|
|
6089
|
+
const obj_excludedGlobalVariables_item = obj_excludedGlobalVariables[i];
|
|
6090
|
+
const path_excludedGlobalVariables_item = path_excludedGlobalVariables + '[' + i + ']';
|
|
6091
|
+
if (typeof obj_excludedGlobalVariables_item !== 'string') {
|
|
6092
|
+
return new TypeError('Expected "string" but received "' + typeof obj_excludedGlobalVariables_item + '" (at "' + path_excludedGlobalVariables_item + '")');
|
|
6093
|
+
}
|
|
6094
|
+
}
|
|
6095
|
+
const obj_schema = obj.schema;
|
|
6096
|
+
const path_schema = path + '.schema';
|
|
6097
|
+
const referencepath_schemaValidationError = validate$4(obj_schema, path_schema);
|
|
6098
|
+
if (referencepath_schemaValidationError !== null) {
|
|
6099
|
+
let message = 'Object doesn\'t match EinsteinPromptTypeSchemaRepresentation (at "' + path_schema + '")\n';
|
|
6100
|
+
message += referencepath_schemaValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
6101
|
+
return new TypeError(message);
|
|
6102
|
+
}
|
|
6103
|
+
const obj_templateTypeName = obj.templateTypeName;
|
|
6104
|
+
const path_templateTypeName = path + '.templateTypeName';
|
|
6105
|
+
if (typeof obj_templateTypeName !== 'string') {
|
|
6106
|
+
return new TypeError('Expected "string" but received "' + typeof obj_templateTypeName + '" (at "' + path_templateTypeName + '")');
|
|
6107
|
+
}
|
|
6108
|
+
})();
|
|
6109
|
+
return v_error === undefined ? null : v_error;
|
|
6110
|
+
}
|
|
6111
|
+
const RepresentationType$1 = 'EinsteinPromptTypeRecordRepresentation';
|
|
6112
|
+
function normalize$1(input, existing, path, luvio, store, timestamp) {
|
|
6113
|
+
return input;
|
|
6114
|
+
}
|
|
6115
|
+
const select$5 = function EinsteinPromptTypeRecordRepresentationSelect() {
|
|
6116
|
+
const { selections: EinsteinPromptTypeSchemaRepresentation__selections, opaque: EinsteinPromptTypeSchemaRepresentation__opaque, } = select$6();
|
|
6117
|
+
return {
|
|
6118
|
+
kind: 'Fragment',
|
|
6119
|
+
version: VERSION$3,
|
|
6120
|
+
private: [],
|
|
6121
|
+
selections: [
|
|
6122
|
+
{
|
|
6123
|
+
name: 'excludedGlobalVariables',
|
|
6124
|
+
kind: 'Scalar',
|
|
6125
|
+
plural: true
|
|
6126
|
+
},
|
|
6127
|
+
{
|
|
6128
|
+
name: 'schema',
|
|
6129
|
+
kind: 'Object',
|
|
6130
|
+
selections: EinsteinPromptTypeSchemaRepresentation__selections
|
|
6131
|
+
},
|
|
6132
|
+
{
|
|
6133
|
+
name: 'templateTypeName',
|
|
6134
|
+
kind: 'Scalar'
|
|
6135
|
+
}
|
|
6136
|
+
]
|
|
6137
|
+
};
|
|
6138
|
+
};
|
|
6139
|
+
function equals$3(existing, incoming) {
|
|
6140
|
+
const existing_templateTypeName = existing.templateTypeName;
|
|
6141
|
+
const incoming_templateTypeName = incoming.templateTypeName;
|
|
6142
|
+
if (!(existing_templateTypeName === incoming_templateTypeName)) {
|
|
6143
|
+
return false;
|
|
6144
|
+
}
|
|
6145
|
+
const existing_excludedGlobalVariables = existing.excludedGlobalVariables;
|
|
6146
|
+
const incoming_excludedGlobalVariables = incoming.excludedGlobalVariables;
|
|
6147
|
+
const equals_excludedGlobalVariables_items = equalsArray(existing_excludedGlobalVariables, incoming_excludedGlobalVariables, (existing_excludedGlobalVariables_item, incoming_excludedGlobalVariables_item) => {
|
|
6148
|
+
if (!(existing_excludedGlobalVariables_item === incoming_excludedGlobalVariables_item)) {
|
|
6149
|
+
return false;
|
|
6150
|
+
}
|
|
6151
|
+
});
|
|
6152
|
+
if (equals_excludedGlobalVariables_items === false) {
|
|
6153
|
+
return false;
|
|
6154
|
+
}
|
|
6155
|
+
const existing_schema = existing.schema;
|
|
6156
|
+
const incoming_schema = incoming.schema;
|
|
6157
|
+
if (!(equals$4(existing_schema, incoming_schema))) {
|
|
6158
|
+
return false;
|
|
6159
|
+
}
|
|
6160
|
+
return true;
|
|
6161
|
+
}
|
|
6162
|
+
const ingest$1 = function EinsteinPromptTypeRecordRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
6163
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
6164
|
+
const validateError = validate$3(input);
|
|
6165
|
+
if (validateError !== null) {
|
|
6166
|
+
throw validateError;
|
|
6167
|
+
}
|
|
6168
|
+
}
|
|
6169
|
+
const key = path.fullPath;
|
|
6170
|
+
const ttlToUse = TTL$1;
|
|
6171
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$1, "EinsteinLLM", VERSION$3, RepresentationType$1, equals$3);
|
|
6172
|
+
return createLink(key);
|
|
6173
|
+
};
|
|
6174
|
+
function getTypeCacheKeys$1(rootKeySet, luvio, input, fullPathFactory) {
|
|
6175
|
+
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
6176
|
+
const rootKey = fullPathFactory();
|
|
6177
|
+
rootKeySet.set(rootKey, {
|
|
6178
|
+
namespace: keyPrefix,
|
|
6179
|
+
representationName: RepresentationType$1,
|
|
6180
|
+
mergeable: false
|
|
6181
|
+
});
|
|
6182
|
+
}
|
|
6183
|
+
|
|
6184
|
+
function select$4(luvio, params) {
|
|
6185
|
+
return select$5();
|
|
6186
|
+
}
|
|
6187
|
+
function keyBuilder$3(luvio, params) {
|
|
6188
|
+
return keyPrefix + '::EinsteinPromptTypeRecordRepresentation:(' + 'templateTypeName:' + params.urlParams.templateTypeName + ')';
|
|
6189
|
+
}
|
|
6190
|
+
function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
|
|
6191
|
+
getTypeCacheKeys$1(storeKeyMap, luvio, response, () => keyBuilder$3(luvio, resourceParams));
|
|
6192
|
+
}
|
|
6193
|
+
function ingestSuccess$1(luvio, resourceParams, response, snapshotRefresh) {
|
|
6194
|
+
const { body } = response;
|
|
6195
|
+
const key = keyBuilder$3(luvio, resourceParams);
|
|
6196
|
+
luvio.storeIngest(key, ingest$1, body);
|
|
6197
|
+
const snapshot = luvio.storeLookup({
|
|
6198
|
+
recordId: key,
|
|
6199
|
+
node: select$4(),
|
|
6200
|
+
variables: {},
|
|
6201
|
+
}, snapshotRefresh);
|
|
6202
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
6203
|
+
if (snapshot.state !== 'Fulfilled') {
|
|
6204
|
+
throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
|
|
6205
|
+
}
|
|
6206
|
+
}
|
|
6207
|
+
deepFreeze(snapshot.data);
|
|
6208
|
+
return snapshot;
|
|
6209
|
+
}
|
|
6210
|
+
function ingestError$1(luvio, params, error, snapshotRefresh) {
|
|
6211
|
+
const key = keyBuilder$3(luvio, params);
|
|
6212
|
+
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
6213
|
+
const storeMetadataParams = {
|
|
6214
|
+
ttl: TTL$1,
|
|
6215
|
+
namespace: keyPrefix,
|
|
6216
|
+
version: VERSION$3,
|
|
6217
|
+
representationName: RepresentationType$1
|
|
6218
|
+
};
|
|
6219
|
+
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
6220
|
+
return errorSnapshot;
|
|
6221
|
+
}
|
|
6222
|
+
function createResourceRequest$1(config) {
|
|
6223
|
+
const headers = {};
|
|
6224
|
+
return {
|
|
6225
|
+
baseUri: '/services/data/v65.0',
|
|
6226
|
+
basePath: '/einstein/prompt-template-types/' + config.urlParams.templateTypeName + '',
|
|
6227
|
+
method: 'get',
|
|
6228
|
+
body: null,
|
|
6229
|
+
urlParams: config.urlParams,
|
|
6230
|
+
queryParams: {},
|
|
6231
|
+
headers,
|
|
6232
|
+
priority: 'normal',
|
|
6233
|
+
};
|
|
6234
|
+
}
|
|
6235
|
+
|
|
6236
|
+
const adapterName$1 = 'getTemplateType';
|
|
6237
|
+
const getTemplateType_ConfigPropertyMetadata = [
|
|
6238
|
+
generateParamConfigMetadata('templateTypeName', true, 0 /* UrlParameter */, 0 /* String */),
|
|
6239
|
+
];
|
|
6240
|
+
const getTemplateType_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, getTemplateType_ConfigPropertyMetadata);
|
|
6241
|
+
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$i(getTemplateType_ConfigPropertyMetadata);
|
|
6242
|
+
function keyBuilder$2(luvio, config) {
|
|
6243
|
+
const resourceParams = createResourceParams$1(config);
|
|
6244
|
+
return keyBuilder$3(luvio, resourceParams);
|
|
6245
|
+
}
|
|
6246
|
+
function typeCheckConfig$1(untrustedConfig) {
|
|
6247
|
+
const config = {};
|
|
6248
|
+
typeCheckConfig$i(untrustedConfig, config, getTemplateType_ConfigPropertyMetadata);
|
|
6249
|
+
return config;
|
|
6250
|
+
}
|
|
6251
|
+
function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
|
|
6252
|
+
if (!untrustedIsObject(untrustedConfig)) {
|
|
6253
|
+
return null;
|
|
6254
|
+
}
|
|
6255
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
6256
|
+
validateConfig(untrustedConfig, configPropertyNames);
|
|
6257
|
+
}
|
|
6258
|
+
const config = typeCheckConfig$1(untrustedConfig);
|
|
6259
|
+
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
6260
|
+
return null;
|
|
6261
|
+
}
|
|
6262
|
+
return config;
|
|
6263
|
+
}
|
|
6264
|
+
function adapterFragment$1(luvio, config) {
|
|
6265
|
+
createResourceParams$1(config);
|
|
6266
|
+
return select$4();
|
|
6267
|
+
}
|
|
6268
|
+
function onFetchResponseSuccess$1(luvio, config, resourceParams, response) {
|
|
6269
|
+
const snapshot = ingestSuccess$1(luvio, resourceParams, response, {
|
|
6270
|
+
config,
|
|
6271
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
6272
|
+
});
|
|
6273
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
6274
|
+
}
|
|
6275
|
+
function onFetchResponseError$1(luvio, config, resourceParams, response) {
|
|
6276
|
+
const snapshot = ingestError$1(luvio, resourceParams, response, {
|
|
6277
|
+
config,
|
|
6278
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
6279
|
+
});
|
|
6280
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
6281
|
+
}
|
|
6282
|
+
function buildNetworkSnapshot$1(luvio, config, options) {
|
|
6283
|
+
const resourceParams = createResourceParams$1(config);
|
|
6284
|
+
const request = createResourceRequest$1(resourceParams);
|
|
6285
|
+
return luvio.dispatchResourceRequest(request, options)
|
|
6286
|
+
.then((response) => {
|
|
6287
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => {
|
|
6288
|
+
const cache = new StoreKeyMap();
|
|
6289
|
+
getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
|
|
6290
|
+
return cache;
|
|
6291
|
+
});
|
|
6292
|
+
}, (response) => {
|
|
6293
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$1(luvio, config, resourceParams, response));
|
|
6294
|
+
});
|
|
6295
|
+
}
|
|
6296
|
+
function buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext) {
|
|
6297
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot$1, undefined, false);
|
|
6298
|
+
}
|
|
6299
|
+
function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
|
|
6300
|
+
const { luvio, config } = context;
|
|
6301
|
+
const selector = {
|
|
6302
|
+
recordId: keyBuilder$2(luvio, config),
|
|
6303
|
+
node: adapterFragment$1(luvio, config),
|
|
6304
|
+
variables: {},
|
|
6305
|
+
};
|
|
6306
|
+
const cacheSnapshot = storeLookup(selector, {
|
|
6307
|
+
config,
|
|
6308
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
6309
|
+
});
|
|
6310
|
+
return cacheSnapshot;
|
|
6311
|
+
}
|
|
6312
|
+
const getTemplateTypeAdapterFactory = (luvio) => function EinsteinLLM__getTemplateType(untrustedConfig, requestContext) {
|
|
6313
|
+
const config = validateAdapterConfig$1(untrustedConfig, getTemplateType_ConfigPropertyNames);
|
|
6314
|
+
// Invalid or incomplete config
|
|
6315
|
+
if (config === null) {
|
|
6316
|
+
return null;
|
|
6317
|
+
}
|
|
6318
|
+
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
6319
|
+
buildCachedSnapshotCachePolicy$1, buildNetworkSnapshotCachePolicy$1);
|
|
6320
|
+
};
|
|
5871
6321
|
|
|
5872
6322
|
const VERSION$2 = "b513bbac1672327d8eaaf120660e94b5";
|
|
5873
6323
|
function validate$2(obj, path = 'EinsteinPromptTemplateSupportedLanguageErrorRepresentation') {
|
|
@@ -6182,14 +6632,14 @@ const getOutputLanguages_ConfigPropertyMetadata = [
|
|
|
6182
6632
|
generateParamConfigMetadata('versionId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
6183
6633
|
];
|
|
6184
6634
|
const getOutputLanguages_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getOutputLanguages_ConfigPropertyMetadata);
|
|
6185
|
-
const createResourceParams = /*#__PURE__*/ createResourceParams$
|
|
6635
|
+
const createResourceParams = /*#__PURE__*/ createResourceParams$i(getOutputLanguages_ConfigPropertyMetadata);
|
|
6186
6636
|
function keyBuilder(luvio, config) {
|
|
6187
6637
|
const resourceParams = createResourceParams(config);
|
|
6188
6638
|
return keyBuilder$1(luvio, resourceParams);
|
|
6189
6639
|
}
|
|
6190
6640
|
function typeCheckConfig(untrustedConfig) {
|
|
6191
6641
|
const config = {};
|
|
6192
|
-
typeCheckConfig$
|
|
6642
|
+
typeCheckConfig$i(untrustedConfig, config, getOutputLanguages_ConfigPropertyMetadata);
|
|
6193
6643
|
return config;
|
|
6194
6644
|
}
|
|
6195
6645
|
function validateAdapterConfig(untrustedConfig, configPropertyNames) {
|
|
@@ -6238,7 +6688,7 @@ function buildNetworkSnapshot(luvio, config, options) {
|
|
|
6238
6688
|
});
|
|
6239
6689
|
}
|
|
6240
6690
|
function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
|
|
6241
|
-
return buildNetworkSnapshotCachePolicy$
|
|
6691
|
+
return buildNetworkSnapshotCachePolicy$b(context, coercedAdapterRequestContext, buildNetworkSnapshot, undefined, false);
|
|
6242
6692
|
}
|
|
6243
6693
|
function buildCachedSnapshotCachePolicy(context, storeLookup) {
|
|
6244
6694
|
const { luvio, config } = context;
|
|
@@ -6263,4 +6713,4 @@ const getOutputLanguagesAdapterFactory = (luvio) => function EinsteinLLM__getOut
|
|
|
6263
6713
|
buildCachedSnapshotCachePolicy, buildNetworkSnapshotCachePolicy);
|
|
6264
6714
|
};
|
|
6265
6715
|
|
|
6266
|
-
export { createEmbeddingsAdapterFactory, createFeedbackAdapterFactory, createGenerationsAdapterFactory, createGenerationsForPromptTemplateAdapterFactory, createPromptTemplateAdapterFactory, createPromptTemplateVersionAdapterFactory, getDataProviderInstanceConfigAdapterFactory, getDataProviderTypeConfigsAdapterFactory, getDataProvidersAdapterFactory, getInputMappedDataProvidersAdapterFactory, getOutputLanguagesAdapterFactory, getPromptTemplateAdapterFactory, getPromptTemplateVersionAdapterFactory, getPromptTemplateVersionsAdapterFactory, getPromptTemplatesAdapterFactory, putEinsteinPromptTemplateVersionStatusAdapterFactory, updatePromptTemplateVersionAdapterFactory };
|
|
6716
|
+
export { createEmbeddingsAdapterFactory, createFeedbackAdapterFactory, createGenerationsAdapterFactory, createGenerationsForPromptTemplateAdapterFactory, createPromptTemplateAdapterFactory, createPromptTemplateVersionAdapterFactory, getDataProviderInstanceConfigAdapterFactory, getDataProviderTypeConfigsAdapterFactory, getDataProvidersAdapterFactory, getInputMappedDataProvidersAdapterFactory, getOutputLanguagesAdapterFactory, getPromptTemplateAdapterFactory, getPromptTemplateVersionAdapterFactory, getPromptTemplateVersionsAdapterFactory, getPromptTemplatesAdapterFactory, getTemplateTypeAdapterFactory, putEinsteinPromptTemplateVersionStatusAdapterFactory, updatePromptTemplateVersionAdapterFactory };
|