@salesforce/lds-adapters-service-einsteinllm 1.380.0-dev1 → 1.380.0-dev10

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.
Files changed (40) hide show
  1. package/dist/es/es2018/service-einsteinllm.js +2229 -493
  2. package/dist/es/es2018/types/src/generated/adapters/createPromptTemplate.d.ts +2 -3
  3. package/dist/es/es2018/types/src/generated/adapters/createPromptTemplateVersion.d.ts +2 -3
  4. package/dist/es/es2018/types/src/generated/adapters/getDataProviderInstanceConfig.d.ts +31 -0
  5. package/dist/es/es2018/types/src/generated/adapters/getDataProviderTypeConfigs.d.ts +27 -0
  6. package/dist/es/es2018/types/src/generated/adapters/getDataProviders.d.ts +29 -0
  7. package/dist/es/es2018/types/src/generated/adapters/getInputMappedDataProviders.d.ts +30 -0
  8. package/dist/es/es2018/types/src/generated/adapters/getPromptTemplateVersion.d.ts +30 -0
  9. package/dist/es/es2018/types/src/generated/adapters/getPromptTemplateVersions.d.ts +29 -0
  10. package/dist/es/es2018/types/src/generated/adapters/putEinsteinPromptTemplateVersionStatus.d.ts +18 -0
  11. package/dist/es/es2018/types/src/generated/adapters/updatePromptTemplateVersion.d.ts +2 -3
  12. package/dist/es/es2018/types/src/generated/artifacts/main.d.ts +7 -0
  13. package/dist/es/es2018/types/src/generated/artifacts/sfdc.d.ts +14 -1
  14. package/dist/es/es2018/types/src/generated/resources/getEinsteinPromptTemplatesDataProviderTypesByTemplateType.d.ts +15 -0
  15. package/dist/es/es2018/types/src/generated/resources/getEinsteinPromptTemplatesDataProvidersByTemplateType.d.ts +19 -0
  16. package/dist/es/es2018/types/src/generated/resources/getEinsteinPromptTemplatesVersionsByPromptTemplateDevName.d.ts +19 -0
  17. package/dist/es/es2018/types/src/generated/resources/getEinsteinPromptTemplatesVersionsByPromptTemplateDevNameAndVersionId.d.ts +20 -0
  18. package/dist/es/es2018/types/src/generated/resources/postEinsteinPromptTemplates.d.ts +2 -3
  19. package/dist/es/es2018/types/src/generated/resources/postEinsteinPromptTemplatesDataProviderDescribe.d.ts +19 -0
  20. package/dist/es/es2018/types/src/generated/resources/postEinsteinPromptTemplatesDataProvidersMapped.d.ts +18 -0
  21. package/dist/es/es2018/types/src/generated/resources/postEinsteinPromptTemplatesVersionsByPromptTemplateDevName.d.ts +2 -3
  22. package/dist/es/es2018/types/src/generated/resources/putEinsteinPromptTemplatesVersionsByPromptTemplateDevNameAndVersionId.d.ts +2 -3
  23. package/dist/es/es2018/types/src/generated/resources/putEinsteinPromptTemplatesVersionsStatusByPromptTemplateDevNameAndVersionId.d.ts +17 -0
  24. package/dist/es/es2018/types/src/generated/types/EinsteinLlmGenerationCitationRepresentation.d.ts +29 -0
  25. package/dist/es/es2018/types/src/generated/types/EinsteinLlmGenerationGenAiCitedReferenceRepresentation.d.ts +40 -0
  26. package/dist/es/es2018/types/src/generated/types/EinsteinPromptRecordInputRepresentation.d.ts +5 -8
  27. package/dist/es/es2018/types/src/generated/types/EinsteinPromptTemplateGenerationsRepresentation.d.ts +7 -1
  28. package/dist/es/es2018/types/src/generated/types/PromptTemplateDataProviderDiscoveryInputRepresentation.d.ts +37 -0
  29. package/dist/es/es2018/types/src/generated/types/PromptTemplateDataProviderInputParamRepresentation.d.ts +37 -0
  30. package/dist/es/es2018/types/src/generated/types/PromptTemplateDataProviderInstanceConfigCollectionRepresentation.d.ts +30 -0
  31. package/dist/es/es2018/types/src/generated/types/PromptTemplateDataProviderInstanceConfigInputRepresentation.d.ts +38 -0
  32. package/dist/es/es2018/types/src/generated/types/PromptTemplateDataProviderInstanceConfigRepresentation.d.ts +77 -0
  33. package/dist/es/es2018/types/src/generated/types/PromptTemplateDataProviderOutputParamRepresentation.d.ts +31 -0
  34. package/dist/es/es2018/types/src/generated/types/PromptTemplateDataProviderTypeConfigCollectionRepresentation.d.ts +30 -0
  35. package/dist/es/es2018/types/src/generated/types/PromptTemplateDataProviderTypeConfigRepresentation.d.ts +46 -0
  36. package/dist/es/es2018/types/src/generated/types/WrappedMap.d.ts +3 -3
  37. package/package.json +4 -4
  38. package/sfdc/index.js +2480 -673
  39. package/src/raml/api.raml +361 -10
  40. package/src/raml/luvio.raml +44 -0
package/sfdc/index.js CHANGED
@@ -14,7 +14,7 @@
14
14
  /* proxy-compat-disable */
15
15
  import { createInstrumentedAdapter, createLDSAdapter, createWireAdapterConstructor, createImperativeAdapter } from 'force/ldsBindings';
16
16
  import { withDefaultLuvio } from 'force/ldsEngine';
17
- import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$4, StoreKeyMap, createResourceParams as createResourceParams$a, typeCheckConfig as typeCheckConfig$a } from 'force/luvioEngine';
17
+ import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$a, StoreKeyMap, createResourceParams as createResourceParams$h, typeCheckConfig as typeCheckConfig$h } from 'force/luvioEngine';
18
18
 
19
19
  const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
20
20
  const { keys: ObjectKeys$1, create: ObjectCreate$1 } = Object;
@@ -178,7 +178,7 @@ function createLink(ref) {
178
178
  };
179
179
  }
180
180
 
181
- function validate$t(obj, path = 'EinsteinLlmEmbeddingsAdditionalConfigInputRepresentation') {
181
+ function validate$B(obj, path = 'EinsteinLlmEmbeddingsAdditionalConfigInputRepresentation') {
182
182
  const v_error = (() => {
183
183
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
184
184
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -222,7 +222,7 @@ function validate$t(obj, path = 'EinsteinLlmEmbeddingsAdditionalConfigInputRepre
222
222
  return v_error === undefined ? null : v_error;
223
223
  }
224
224
 
225
- function validate$s(obj, path = 'WrappedListString') {
225
+ function validate$A(obj, path = 'WrappedListString') {
226
226
  const v_error = (() => {
227
227
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
228
228
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -243,14 +243,14 @@ function validate$s(obj, path = 'WrappedListString') {
243
243
  return v_error === undefined ? null : v_error;
244
244
  }
245
245
 
246
- function validate$r(obj, path = 'EinsteinLlmEmbeddingsInputRepresentation') {
246
+ function validate$z(obj, path = 'EinsteinLlmEmbeddingsInputRepresentation') {
247
247
  const v_error = (() => {
248
248
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
249
249
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
250
250
  }
251
251
  const obj_additionalConfig = obj.additionalConfig;
252
252
  const path_additionalConfig = path + '.additionalConfig';
253
- const referencepath_additionalConfigValidationError = validate$t(obj_additionalConfig, path_additionalConfig);
253
+ const referencepath_additionalConfigValidationError = validate$B(obj_additionalConfig, path_additionalConfig);
254
254
  if (referencepath_additionalConfigValidationError !== null) {
255
255
  let message = 'Object doesn\'t match EinsteinLlmEmbeddingsAdditionalConfigInputRepresentation (at "' + path_additionalConfig + '")\n';
256
256
  message += referencepath_additionalConfigValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -258,7 +258,7 @@ function validate$r(obj, path = 'EinsteinLlmEmbeddingsInputRepresentation') {
258
258
  }
259
259
  const obj_prompts = obj.prompts;
260
260
  const path_prompts = path + '.prompts';
261
- const referencepath_promptsValidationError = validate$s(obj_prompts, path_prompts);
261
+ const referencepath_promptsValidationError = validate$A(obj_prompts, path_prompts);
262
262
  if (referencepath_promptsValidationError !== null) {
263
263
  let message = 'Object doesn\'t match WrappedListString (at "' + path_prompts + '")\n';
264
264
  message += referencepath_promptsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -275,8 +275,8 @@ function validate$r(obj, path = 'EinsteinLlmEmbeddingsInputRepresentation') {
275
275
  return v_error === undefined ? null : v_error;
276
276
  }
277
277
 
278
- const VERSION$k = "5ed5ccc6fa6f15691ec0fc1080e41fe6";
279
- function validate$q(obj, path = 'EinsteinLlmEmbeddingItemRepresentation') {
278
+ const VERSION$p = "5ed5ccc6fa6f15691ec0fc1080e41fe6";
279
+ function validate$y(obj, path = 'EinsteinLlmEmbeddingItemRepresentation') {
280
280
  const v_error = (() => {
281
281
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
282
282
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -297,10 +297,10 @@ function validate$q(obj, path = 'EinsteinLlmEmbeddingItemRepresentation') {
297
297
  })();
298
298
  return v_error === undefined ? null : v_error;
299
299
  }
300
- const select$u = function EinsteinLlmEmbeddingItemRepresentationSelect() {
300
+ const select$G = function EinsteinLlmEmbeddingItemRepresentationSelect() {
301
301
  return {
302
302
  kind: 'Fragment',
303
- version: VERSION$k,
303
+ version: VERSION$p,
304
304
  private: [],
305
305
  selections: [
306
306
  {
@@ -315,7 +315,7 @@ const select$u = function EinsteinLlmEmbeddingItemRepresentationSelect() {
315
315
  ]
316
316
  };
317
317
  };
318
- function equals$k(existing, incoming) {
318
+ function equals$p(existing, incoming) {
319
319
  const existing_index = existing.index;
320
320
  const incoming_index = incoming.index;
321
321
  if (!(existing_index === incoming_index)) {
@@ -334,9 +334,9 @@ function equals$k(existing, incoming) {
334
334
  return true;
335
335
  }
336
336
 
337
- const TTL$7 = 100;
338
- const VERSION$j = "d9873651f09d29764ef4d4231eb653d7";
339
- function validate$p(obj, path = 'EinsteinLlmEmbeddingsRepresentation') {
337
+ const TTL$a = 100;
338
+ const VERSION$o = "d9873651f09d29764ef4d4231eb653d7";
339
+ function validate$x(obj, path = 'EinsteinLlmEmbeddingsRepresentation') {
340
340
  const v_error = (() => {
341
341
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
342
342
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -349,7 +349,7 @@ function validate$p(obj, path = 'EinsteinLlmEmbeddingsRepresentation') {
349
349
  for (let i = 0; i < obj_embeddings.length; i++) {
350
350
  const obj_embeddings_item = obj_embeddings[i];
351
351
  const path_embeddings_item = path_embeddings + '[' + i + ']';
352
- const referencepath_embeddings_itemValidationError = validate$q(obj_embeddings_item, path_embeddings_item);
352
+ const referencepath_embeddings_itemValidationError = validate$y(obj_embeddings_item, path_embeddings_item);
353
353
  if (referencepath_embeddings_itemValidationError !== null) {
354
354
  let message = 'Object doesn\'t match EinsteinLlmEmbeddingItemRepresentation (at "' + path_embeddings_item + '")\n';
355
355
  message += referencepath_embeddings_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -373,15 +373,15 @@ function validate$p(obj, path = 'EinsteinLlmEmbeddingsRepresentation') {
373
373
  })();
374
374
  return v_error === undefined ? null : v_error;
375
375
  }
376
- const RepresentationType$7 = 'EinsteinLlmEmbeddingsRepresentation';
377
- function normalize$7(input, existing, path, luvio, store, timestamp) {
376
+ const RepresentationType$a = 'EinsteinLlmEmbeddingsRepresentation';
377
+ function normalize$a(input, existing, path, luvio, store, timestamp) {
378
378
  return input;
379
379
  }
380
- const select$t = function EinsteinLlmEmbeddingsRepresentationSelect() {
381
- const { selections: EinsteinLlmEmbeddingItemRepresentation__selections, opaque: EinsteinLlmEmbeddingItemRepresentation__opaque, } = select$u();
380
+ const select$F = function EinsteinLlmEmbeddingsRepresentationSelect() {
381
+ const { selections: EinsteinLlmEmbeddingItemRepresentation__selections, opaque: EinsteinLlmEmbeddingItemRepresentation__opaque, } = select$G();
382
382
  return {
383
383
  kind: 'Fragment',
384
- version: VERSION$j,
384
+ version: VERSION$o,
385
385
  private: [],
386
386
  selections: [
387
387
  {
@@ -398,11 +398,11 @@ const select$t = function EinsteinLlmEmbeddingsRepresentationSelect() {
398
398
  ]
399
399
  };
400
400
  };
401
- function equals$j(existing, incoming) {
401
+ function equals$o(existing, incoming) {
402
402
  const existing_embeddings = existing.embeddings;
403
403
  const incoming_embeddings = incoming.embeddings;
404
404
  const equals_embeddings_items = equalsArray(existing_embeddings, incoming_embeddings, (existing_embeddings_item, incoming_embeddings_item) => {
405
- if (!(equals$k(existing_embeddings_item, incoming_embeddings_item))) {
405
+ if (!(equals$p(existing_embeddings_item, incoming_embeddings_item))) {
406
406
  return false;
407
407
  }
408
408
  });
@@ -421,44 +421,44 @@ function equals$j(existing, incoming) {
421
421
  }
422
422
  return true;
423
423
  }
424
- const ingest$7 = function EinsteinLlmEmbeddingsRepresentationIngest(input, path, luvio, store, timestamp) {
424
+ const ingest$a = function EinsteinLlmEmbeddingsRepresentationIngest(input, path, luvio, store, timestamp) {
425
425
  if (process.env.NODE_ENV !== 'production') {
426
- const validateError = validate$p(input);
426
+ const validateError = validate$x(input);
427
427
  if (validateError !== null) {
428
428
  throw validateError;
429
429
  }
430
430
  }
431
431
  const key = path.fullPath;
432
- const ttlToUse = TTL$7;
433
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$7, "EinsteinLLM", VERSION$j, RepresentationType$7, equals$j);
432
+ const ttlToUse = TTL$a;
433
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$a, "EinsteinLLM", VERSION$o, RepresentationType$a, equals$o);
434
434
  return createLink(key);
435
435
  };
436
- function getTypeCacheKeys$7(rootKeySet, luvio, input, fullPathFactory) {
436
+ function getTypeCacheKeys$a(rootKeySet, luvio, input, fullPathFactory) {
437
437
  // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
438
438
  const rootKey = fullPathFactory();
439
439
  rootKeySet.set(rootKey, {
440
440
  namespace: keyPrefix,
441
- representationName: RepresentationType$7,
441
+ representationName: RepresentationType$a,
442
442
  mergeable: false
443
443
  });
444
444
  }
445
445
 
446
- function select$s(luvio, params) {
447
- return select$t();
446
+ function select$E(luvio, params) {
447
+ return select$F();
448
448
  }
449
- function keyBuilder$b(luvio, params) {
449
+ function keyBuilder$n(luvio, params) {
450
450
  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) + ')';
451
451
  }
452
- function getResponseCacheKeys$9(storeKeyMap, luvio, resourceParams, response) {
453
- getTypeCacheKeys$7(storeKeyMap, luvio, response, () => keyBuilder$b(luvio, resourceParams));
452
+ function getResponseCacheKeys$g(storeKeyMap, luvio, resourceParams, response) {
453
+ getTypeCacheKeys$a(storeKeyMap, luvio, response, () => keyBuilder$n(luvio, resourceParams));
454
454
  }
455
- function ingestSuccess$9(luvio, resourceParams, response, snapshotRefresh) {
455
+ function ingestSuccess$g(luvio, resourceParams, response, snapshotRefresh) {
456
456
  const { body } = response;
457
- const key = keyBuilder$b(luvio, resourceParams);
458
- luvio.storeIngest(key, ingest$7, body);
457
+ const key = keyBuilder$n(luvio, resourceParams);
458
+ luvio.storeIngest(key, ingest$a, body);
459
459
  const snapshot = luvio.storeLookup({
460
460
  recordId: key,
461
- node: select$s(),
461
+ node: select$E(),
462
462
  variables: {},
463
463
  }, snapshotRefresh);
464
464
  if (process.env.NODE_ENV !== 'production') {
@@ -469,19 +469,19 @@ function ingestSuccess$9(luvio, resourceParams, response, snapshotRefresh) {
469
469
  deepFreeze(snapshot.data);
470
470
  return snapshot;
471
471
  }
472
- function ingestError$3(luvio, params, error, snapshotRefresh) {
473
- const key = keyBuilder$b(luvio, params);
472
+ function ingestError$9(luvio, params, error, snapshotRefresh) {
473
+ const key = keyBuilder$n(luvio, params);
474
474
  const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
475
475
  const storeMetadataParams = {
476
- ttl: TTL$7,
476
+ ttl: TTL$a,
477
477
  namespace: keyPrefix,
478
- version: VERSION$j,
479
- representationName: RepresentationType$7
478
+ version: VERSION$o,
479
+ representationName: RepresentationType$a
480
480
  };
481
481
  luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
482
482
  return errorSnapshot;
483
483
  }
484
- function createResourceRequest$9(config) {
484
+ function createResourceRequest$g(config) {
485
485
  const headers = {};
486
486
  return {
487
487
  baseUri: '/services/data/v65.0',
@@ -495,97 +495,97 @@ function createResourceRequest$9(config) {
495
495
  };
496
496
  }
497
497
 
498
- const adapterName$9 = 'createEmbeddings';
498
+ const adapterName$g = 'createEmbeddings';
499
499
  const createEmbeddings_ConfigPropertyMetadata = [
500
500
  generateParamConfigMetadata('embeddingsInput', true, 2 /* Body */, 4 /* Unsupported */),
501
501
  ];
502
- const createEmbeddings_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$9, createEmbeddings_ConfigPropertyMetadata);
503
- const createResourceParams$9 = /*#__PURE__*/ createResourceParams$a(createEmbeddings_ConfigPropertyMetadata);
504
- function keyBuilder$a(luvio, config) {
505
- const resourceParams = createResourceParams$9(config);
506
- return keyBuilder$b(luvio, resourceParams);
502
+ const createEmbeddings_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$g, createEmbeddings_ConfigPropertyMetadata);
503
+ const createResourceParams$g = /*#__PURE__*/ createResourceParams$h(createEmbeddings_ConfigPropertyMetadata);
504
+ function keyBuilder$m(luvio, config) {
505
+ const resourceParams = createResourceParams$g(config);
506
+ return keyBuilder$n(luvio, resourceParams);
507
507
  }
508
- function typeCheckConfig$9(untrustedConfig) {
508
+ function typeCheckConfig$g(untrustedConfig) {
509
509
  const config = {};
510
510
  const untrustedConfig_embeddingsInput = untrustedConfig.embeddingsInput;
511
- const referenceEinsteinLlmEmbeddingsInputRepresentationValidationError = validate$r(untrustedConfig_embeddingsInput);
511
+ const referenceEinsteinLlmEmbeddingsInputRepresentationValidationError = validate$z(untrustedConfig_embeddingsInput);
512
512
  if (referenceEinsteinLlmEmbeddingsInputRepresentationValidationError === null) {
513
513
  config.embeddingsInput = untrustedConfig_embeddingsInput;
514
514
  }
515
515
  return config;
516
516
  }
517
- function validateAdapterConfig$9(untrustedConfig, configPropertyNames) {
517
+ function validateAdapterConfig$g(untrustedConfig, configPropertyNames) {
518
518
  if (!untrustedIsObject(untrustedConfig)) {
519
519
  return null;
520
520
  }
521
521
  if (process.env.NODE_ENV !== 'production') {
522
522
  validateConfig(untrustedConfig, configPropertyNames);
523
523
  }
524
- const config = typeCheckConfig$9(untrustedConfig);
524
+ const config = typeCheckConfig$g(untrustedConfig);
525
525
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
526
526
  return null;
527
527
  }
528
528
  return config;
529
529
  }
530
- function adapterFragment$3(luvio, config) {
531
- createResourceParams$9(config);
532
- return select$s();
530
+ function adapterFragment$9(luvio, config) {
531
+ createResourceParams$g(config);
532
+ return select$E();
533
533
  }
534
- function onFetchResponseSuccess$3(luvio, config, resourceParams, response) {
535
- const snapshot = ingestSuccess$9(luvio, resourceParams, response, {
534
+ function onFetchResponseSuccess$9(luvio, config, resourceParams, response) {
535
+ const snapshot = ingestSuccess$g(luvio, resourceParams, response, {
536
536
  config,
537
- resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
537
+ resolve: () => buildNetworkSnapshot$g(luvio, config, snapshotRefreshOptions)
538
538
  });
539
539
  return luvio.storeBroadcast().then(() => snapshot);
540
540
  }
541
- function onFetchResponseError$3(luvio, config, resourceParams, response) {
542
- const snapshot = ingestError$3(luvio, resourceParams, response, {
541
+ function onFetchResponseError$9(luvio, config, resourceParams, response) {
542
+ const snapshot = ingestError$9(luvio, resourceParams, response, {
543
543
  config,
544
- resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
544
+ resolve: () => buildNetworkSnapshot$g(luvio, config, snapshotRefreshOptions)
545
545
  });
546
546
  return luvio.storeBroadcast().then(() => snapshot);
547
547
  }
548
- function buildNetworkSnapshot$9(luvio, config, options) {
549
- const resourceParams = createResourceParams$9(config);
550
- const request = createResourceRequest$9(resourceParams);
548
+ function buildNetworkSnapshot$g(luvio, config, options) {
549
+ const resourceParams = createResourceParams$g(config);
550
+ const request = createResourceRequest$g(resourceParams);
551
551
  return luvio.dispatchResourceRequest(request, options)
552
552
  .then((response) => {
553
- return luvio.handleSuccessResponse(() => onFetchResponseSuccess$3(luvio, config, resourceParams, response), () => {
553
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$9(luvio, config, resourceParams, response), () => {
554
554
  const cache = new StoreKeyMap();
555
- getResponseCacheKeys$9(cache, luvio, resourceParams, response.body);
555
+ getResponseCacheKeys$g(cache, luvio, resourceParams, response.body);
556
556
  return cache;
557
557
  });
558
558
  }, (response) => {
559
- return luvio.handleErrorResponse(() => onFetchResponseError$3(luvio, config, resourceParams, response));
559
+ return luvio.handleErrorResponse(() => onFetchResponseError$9(luvio, config, resourceParams, response));
560
560
  });
561
561
  }
562
- function buildNetworkSnapshotCachePolicy$3(context, coercedAdapterRequestContext) {
563
- return buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext, buildNetworkSnapshot$9, 'get', false);
562
+ function buildNetworkSnapshotCachePolicy$9(context, coercedAdapterRequestContext) {
563
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$g, 'get', false);
564
564
  }
565
- function buildCachedSnapshotCachePolicy$3(context, storeLookup) {
565
+ function buildCachedSnapshotCachePolicy$9(context, storeLookup) {
566
566
  const { luvio, config } = context;
567
567
  const selector = {
568
- recordId: keyBuilder$a(luvio, config),
569
- node: adapterFragment$3(luvio, config),
568
+ recordId: keyBuilder$m(luvio, config),
569
+ node: adapterFragment$9(luvio, config),
570
570
  variables: {},
571
571
  };
572
572
  const cacheSnapshot = storeLookup(selector, {
573
573
  config,
574
- resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
574
+ resolve: () => buildNetworkSnapshot$g(luvio, config, snapshotRefreshOptions)
575
575
  });
576
576
  return cacheSnapshot;
577
577
  }
578
578
  const createEmbeddingsAdapterFactory = (luvio) => function EinsteinLLM__createEmbeddings(untrustedConfig, requestContext) {
579
- const config = validateAdapterConfig$9(untrustedConfig, createEmbeddings_ConfigPropertyNames);
579
+ const config = validateAdapterConfig$g(untrustedConfig, createEmbeddings_ConfigPropertyNames);
580
580
  // Invalid or incomplete config
581
581
  if (config === null) {
582
582
  return null;
583
583
  }
584
584
  return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
585
- buildCachedSnapshotCachePolicy$3, buildNetworkSnapshotCachePolicy$3);
585
+ buildCachedSnapshotCachePolicy$9, buildNetworkSnapshotCachePolicy$9);
586
586
  };
587
587
 
588
- function validate$o(obj, path = 'EinsteinLlmFeedbackInputRepresentation') {
588
+ function validate$w(obj, path = 'EinsteinLlmFeedbackInputRepresentation') {
589
589
  const v_error = (() => {
590
590
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
591
591
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -632,9 +632,9 @@ function validate$o(obj, path = 'EinsteinLlmFeedbackInputRepresentation') {
632
632
  return v_error === undefined ? null : v_error;
633
633
  }
634
634
 
635
- const TTL$6 = 100;
636
- const VERSION$i = "4033328f65865dd5d80c68a7573a4522";
637
- function validate$n(obj, path = 'EinsteinLlmFeedbackRepresentation') {
635
+ const TTL$9 = 100;
636
+ const VERSION$n = "4033328f65865dd5d80c68a7573a4522";
637
+ function validate$v(obj, path = 'EinsteinLlmFeedbackRepresentation') {
638
638
  const v_error = (() => {
639
639
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
640
640
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -647,23 +647,23 @@ function validate$n(obj, path = 'EinsteinLlmFeedbackRepresentation') {
647
647
  })();
648
648
  return v_error === undefined ? null : v_error;
649
649
  }
650
- const RepresentationType$6 = 'EinsteinLlmFeedbackRepresentation';
651
- function keyBuilder$9(luvio, config) {
652
- return keyPrefix + '::' + RepresentationType$6 + ':' + config.message;
650
+ const RepresentationType$9 = 'EinsteinLlmFeedbackRepresentation';
651
+ function keyBuilder$l(luvio, config) {
652
+ return keyPrefix + '::' + RepresentationType$9 + ':' + config.message;
653
653
  }
654
654
  function keyBuilderFromType$3(luvio, object) {
655
655
  const keyParams = {
656
656
  message: object.message
657
657
  };
658
- return keyBuilder$9(luvio, keyParams);
658
+ return keyBuilder$l(luvio, keyParams);
659
659
  }
660
- function normalize$6(input, existing, path, luvio, store, timestamp) {
660
+ function normalize$9(input, existing, path, luvio, store, timestamp) {
661
661
  return input;
662
662
  }
663
- const select$r = function EinsteinLlmFeedbackRepresentationSelect() {
663
+ const select$D = function EinsteinLlmFeedbackRepresentationSelect() {
664
664
  return {
665
665
  kind: 'Fragment',
666
- version: VERSION$i,
666
+ version: VERSION$n,
667
667
  private: [],
668
668
  selections: [
669
669
  {
@@ -673,7 +673,7 @@ const select$r = function EinsteinLlmFeedbackRepresentationSelect() {
673
673
  ]
674
674
  };
675
675
  };
676
- function equals$i(existing, incoming) {
676
+ function equals$n(existing, incoming) {
677
677
  const existing_message = existing.message;
678
678
  const incoming_message = incoming.message;
679
679
  if (!(existing_message === incoming_message)) {
@@ -681,41 +681,41 @@ function equals$i(existing, incoming) {
681
681
  }
682
682
  return true;
683
683
  }
684
- const ingest$6 = function EinsteinLlmFeedbackRepresentationIngest(input, path, luvio, store, timestamp) {
684
+ const ingest$9 = function EinsteinLlmFeedbackRepresentationIngest(input, path, luvio, store, timestamp) {
685
685
  if (process.env.NODE_ENV !== 'production') {
686
- const validateError = validate$n(input);
686
+ const validateError = validate$v(input);
687
687
  if (validateError !== null) {
688
688
  throw validateError;
689
689
  }
690
690
  }
691
691
  const key = keyBuilderFromType$3(luvio, input);
692
- const ttlToUse = TTL$6;
693
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$6, "EinsteinLLM", VERSION$i, RepresentationType$6, equals$i);
692
+ const ttlToUse = TTL$9;
693
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$9, "EinsteinLLM", VERSION$n, RepresentationType$9, equals$n);
694
694
  return createLink(key);
695
695
  };
696
- function getTypeCacheKeys$6(rootKeySet, luvio, input, fullPathFactory) {
696
+ function getTypeCacheKeys$9(rootKeySet, luvio, input, fullPathFactory) {
697
697
  // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
698
698
  const rootKey = keyBuilderFromType$3(luvio, input);
699
699
  rootKeySet.set(rootKey, {
700
700
  namespace: keyPrefix,
701
- representationName: RepresentationType$6,
701
+ representationName: RepresentationType$9,
702
702
  mergeable: false
703
703
  });
704
704
  }
705
705
 
706
- function select$q(luvio, params) {
707
- return select$r();
706
+ function select$C(luvio, params) {
707
+ return select$D();
708
708
  }
709
- function getResponseCacheKeys$8(storeKeyMap, luvio, resourceParams, response) {
710
- getTypeCacheKeys$6(storeKeyMap, luvio, response);
709
+ function getResponseCacheKeys$f(storeKeyMap, luvio, resourceParams, response) {
710
+ getTypeCacheKeys$9(storeKeyMap, luvio, response);
711
711
  }
712
- function ingestSuccess$8(luvio, resourceParams, response) {
712
+ function ingestSuccess$f(luvio, resourceParams, response) {
713
713
  const { body } = response;
714
714
  const key = keyBuilderFromType$3(luvio, body);
715
- luvio.storeIngest(key, ingest$6, body);
715
+ luvio.storeIngest(key, ingest$9, body);
716
716
  const snapshot = luvio.storeLookup({
717
717
  recordId: key,
718
- node: select$q(),
718
+ node: select$C(),
719
719
  variables: {},
720
720
  });
721
721
  if (process.env.NODE_ENV !== 'production') {
@@ -726,7 +726,7 @@ function ingestSuccess$8(luvio, resourceParams, response) {
726
726
  deepFreeze(snapshot.data);
727
727
  return snapshot;
728
728
  }
729
- function createResourceRequest$8(config) {
729
+ function createResourceRequest$f(config) {
730
730
  const headers = {};
731
731
  return {
732
732
  baseUri: '/services/data/v65.0',
@@ -740,45 +740,45 @@ function createResourceRequest$8(config) {
740
740
  };
741
741
  }
742
742
 
743
- const adapterName$8 = 'createFeedback';
743
+ const adapterName$f = 'createFeedback';
744
744
  const createFeedback_ConfigPropertyMetadata = [
745
745
  generateParamConfigMetadata('feedbackInput', true, 2 /* Body */, 4 /* Unsupported */),
746
746
  ];
747
- const createFeedback_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$8, createFeedback_ConfigPropertyMetadata);
748
- const createResourceParams$8 = /*#__PURE__*/ createResourceParams$a(createFeedback_ConfigPropertyMetadata);
749
- function typeCheckConfig$8(untrustedConfig) {
747
+ const createFeedback_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$f, createFeedback_ConfigPropertyMetadata);
748
+ const createResourceParams$f = /*#__PURE__*/ createResourceParams$h(createFeedback_ConfigPropertyMetadata);
749
+ function typeCheckConfig$f(untrustedConfig) {
750
750
  const config = {};
751
751
  const untrustedConfig_feedbackInput = untrustedConfig.feedbackInput;
752
- const referenceEinsteinLlmFeedbackInputRepresentationValidationError = validate$o(untrustedConfig_feedbackInput);
752
+ const referenceEinsteinLlmFeedbackInputRepresentationValidationError = validate$w(untrustedConfig_feedbackInput);
753
753
  if (referenceEinsteinLlmFeedbackInputRepresentationValidationError === null) {
754
754
  config.feedbackInput = untrustedConfig_feedbackInput;
755
755
  }
756
756
  return config;
757
757
  }
758
- function validateAdapterConfig$8(untrustedConfig, configPropertyNames) {
758
+ function validateAdapterConfig$f(untrustedConfig, configPropertyNames) {
759
759
  if (!untrustedIsObject(untrustedConfig)) {
760
760
  return null;
761
761
  }
762
762
  if (process.env.NODE_ENV !== 'production') {
763
763
  validateConfig(untrustedConfig, configPropertyNames);
764
764
  }
765
- const config = typeCheckConfig$8(untrustedConfig);
765
+ const config = typeCheckConfig$f(untrustedConfig);
766
766
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
767
767
  return null;
768
768
  }
769
769
  return config;
770
770
  }
771
- function buildNetworkSnapshot$8(luvio, config, options) {
772
- const resourceParams = createResourceParams$8(config);
773
- const request = createResourceRequest$8(resourceParams);
771
+ function buildNetworkSnapshot$f(luvio, config, options) {
772
+ const resourceParams = createResourceParams$f(config);
773
+ const request = createResourceRequest$f(resourceParams);
774
774
  return luvio.dispatchResourceRequest(request, options)
775
775
  .then((response) => {
776
776
  return luvio.handleSuccessResponse(() => {
777
- const snapshot = ingestSuccess$8(luvio, resourceParams, response);
777
+ const snapshot = ingestSuccess$f(luvio, resourceParams, response);
778
778
  return luvio.storeBroadcast().then(() => snapshot);
779
779
  }, () => {
780
780
  const cache = new StoreKeyMap();
781
- getResponseCacheKeys$8(cache, luvio, resourceParams, response.body);
781
+ getResponseCacheKeys$f(cache, luvio, resourceParams, response.body);
782
782
  return cache;
783
783
  });
784
784
  }, (response) => {
@@ -788,16 +788,16 @@ function buildNetworkSnapshot$8(luvio, config, options) {
788
788
  }
789
789
  const createFeedbackAdapterFactory = (luvio) => {
790
790
  return function createFeedback(untrustedConfig) {
791
- const config = validateAdapterConfig$8(untrustedConfig, createFeedback_ConfigPropertyNames);
791
+ const config = validateAdapterConfig$f(untrustedConfig, createFeedback_ConfigPropertyNames);
792
792
  // Invalid or incomplete config
793
793
  if (config === null) {
794
794
  throw new Error('Invalid config for "createFeedback"');
795
795
  }
796
- return buildNetworkSnapshot$8(luvio, config);
796
+ return buildNetworkSnapshot$f(luvio, config);
797
797
  };
798
798
  };
799
799
 
800
- function validate$m(obj, path = 'EinsteinLlmAdditionalConfigInputRepresentation') {
800
+ function validate$u(obj, path = 'EinsteinLlmAdditionalConfigInputRepresentation') {
801
801
  const v_error = (() => {
802
802
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
803
803
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -880,7 +880,7 @@ function validate$m(obj, path = 'EinsteinLlmAdditionalConfigInputRepresentation'
880
880
  return v_error === undefined ? null : v_error;
881
881
  }
882
882
 
883
- function validate$l(obj, path = 'EinsteinLlmGenerationsInputRepresentation') {
883
+ function validate$t(obj, path = 'EinsteinLlmGenerationsInputRepresentation') {
884
884
  const v_error = (() => {
885
885
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
886
886
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -888,7 +888,7 @@ function validate$l(obj, path = 'EinsteinLlmGenerationsInputRepresentation') {
888
888
  if (obj.additionalConfig !== undefined) {
889
889
  const obj_additionalConfig = obj.additionalConfig;
890
890
  const path_additionalConfig = path + '.additionalConfig';
891
- const referencepath_additionalConfigValidationError = validate$m(obj_additionalConfig, path_additionalConfig);
891
+ const referencepath_additionalConfigValidationError = validate$u(obj_additionalConfig, path_additionalConfig);
892
892
  if (referencepath_additionalConfigValidationError !== null) {
893
893
  let message = 'Object doesn\'t match EinsteinLlmAdditionalConfigInputRepresentation (at "' + path_additionalConfig + '")\n';
894
894
  message += referencepath_additionalConfigValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -911,8 +911,8 @@ function validate$l(obj, path = 'EinsteinLlmGenerationsInputRepresentation') {
911
911
  return v_error === undefined ? null : v_error;
912
912
  }
913
913
 
914
- const VERSION$h = "9ebac74e6f964c363d5fd1913df363af";
915
- function validate$k(obj, path = 'EinsteinLlmGenerationsContentQualityRepresentation') {
914
+ const VERSION$m = "9ebac74e6f964c363d5fd1913df363af";
915
+ function validate$s(obj, path = 'EinsteinLlmGenerationsContentQualityRepresentation') {
916
916
  const v_error = (() => {
917
917
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
918
918
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -948,10 +948,10 @@ function validate$k(obj, path = 'EinsteinLlmGenerationsContentQualityRepresentat
948
948
  })();
949
949
  return v_error === undefined ? null : v_error;
950
950
  }
951
- const select$p = function EinsteinLlmGenerationsContentQualityRepresentationSelect() {
951
+ const select$B = function EinsteinLlmGenerationsContentQualityRepresentationSelect() {
952
952
  return {
953
953
  kind: 'Fragment',
954
- version: VERSION$h,
954
+ version: VERSION$m,
955
955
  private: [],
956
956
  selections: [
957
957
  {
@@ -962,7 +962,7 @@ const select$p = function EinsteinLlmGenerationsContentQualityRepresentationSele
962
962
  ]
963
963
  };
964
964
  };
965
- function equals$h(existing, incoming) {
965
+ function equals$m(existing, incoming) {
966
966
  const existing_isToxicityDetected = existing.isToxicityDetected;
967
967
  const incoming_isToxicityDetected = incoming.isToxicityDetected;
968
968
  // if at least one of these optionals is defined
@@ -979,8 +979,8 @@ function equals$h(existing, incoming) {
979
979
  return true;
980
980
  }
981
981
 
982
- const VERSION$g = "77af44a252cb5b45b4d9a8101368d2aa";
983
- function validate$j(obj, path = 'EinsteinLlmGenerationsSafetyScoreRepresentation') {
982
+ const VERSION$l = "77af44a252cb5b45b4d9a8101368d2aa";
983
+ function validate$r(obj, path = 'EinsteinLlmGenerationsSafetyScoreRepresentation') {
984
984
  const v_error = (() => {
985
985
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
986
986
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -1184,10 +1184,10 @@ function validate$j(obj, path = 'EinsteinLlmGenerationsSafetyScoreRepresentation
1184
1184
  })();
1185
1185
  return v_error === undefined ? null : v_error;
1186
1186
  }
1187
- const select$o = function EinsteinLlmGenerationsSafetyScoreRepresentationSelect() {
1187
+ const select$A = function EinsteinLlmGenerationsSafetyScoreRepresentationSelect() {
1188
1188
  return {
1189
1189
  kind: 'Fragment',
1190
- version: VERSION$g,
1190
+ version: VERSION$l,
1191
1191
  private: [],
1192
1192
  selections: [
1193
1193
  {
@@ -1228,7 +1228,7 @@ const select$o = function EinsteinLlmGenerationsSafetyScoreRepresentationSelect(
1228
1228
  ]
1229
1229
  };
1230
1230
  };
1231
- function equals$g(existing, incoming) {
1231
+ function equals$l(existing, incoming) {
1232
1232
  const existing_hateScore = existing.hateScore;
1233
1233
  const incoming_hateScore = incoming.hateScore;
1234
1234
  // if at least one of these optionals is defined
@@ -1323,8 +1323,8 @@ function equals$g(existing, incoming) {
1323
1323
  return true;
1324
1324
  }
1325
1325
 
1326
- const VERSION$f = "4a07778ff6c595d91c575188146647a1";
1327
- function validate$i(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
1326
+ const VERSION$k = "4a07778ff6c595d91c575188146647a1";
1327
+ function validate$q(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
1328
1328
  const v_error = (() => {
1329
1329
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1330
1330
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -1334,7 +1334,7 @@ function validate$i(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
1334
1334
  const path_contentQualityRepresentation = path + '.contentQualityRepresentation';
1335
1335
  let obj_contentQualityRepresentation_union0 = null;
1336
1336
  const obj_contentQualityRepresentation_union0_error = (() => {
1337
- const referencepath_contentQualityRepresentationValidationError = validate$k(obj_contentQualityRepresentation, path_contentQualityRepresentation);
1337
+ const referencepath_contentQualityRepresentationValidationError = validate$s(obj_contentQualityRepresentation, path_contentQualityRepresentation);
1338
1338
  if (referencepath_contentQualityRepresentationValidationError !== null) {
1339
1339
  let message = 'Object doesn\'t match EinsteinLlmGenerationsContentQualityRepresentation (at "' + path_contentQualityRepresentation + '")\n';
1340
1340
  message += referencepath_contentQualityRepresentationValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -1382,7 +1382,7 @@ function validate$i(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
1382
1382
  const path_safetyScoreRepresentation = path + '.safetyScoreRepresentation';
1383
1383
  let obj_safetyScoreRepresentation_union0 = null;
1384
1384
  const obj_safetyScoreRepresentation_union0_error = (() => {
1385
- const referencepath_safetyScoreRepresentationValidationError = validate$j(obj_safetyScoreRepresentation, path_safetyScoreRepresentation);
1385
+ const referencepath_safetyScoreRepresentationValidationError = validate$r(obj_safetyScoreRepresentation, path_safetyScoreRepresentation);
1386
1386
  if (referencepath_safetyScoreRepresentationValidationError !== null) {
1387
1387
  let message = 'Object doesn\'t match EinsteinLlmGenerationsSafetyScoreRepresentation (at "' + path_safetyScoreRepresentation + '")\n';
1388
1388
  message += referencepath_safetyScoreRepresentationValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -1416,12 +1416,12 @@ function validate$i(obj, path = 'EinsteinLlmGenerationItemRepresentation') {
1416
1416
  })();
1417
1417
  return v_error === undefined ? null : v_error;
1418
1418
  }
1419
- const select$n = function EinsteinLlmGenerationItemRepresentationSelect() {
1420
- const { selections: EinsteinLlmGenerationsContentQualityRepresentation__selections, opaque: EinsteinLlmGenerationsContentQualityRepresentation__opaque, } = select$p();
1421
- const { selections: EinsteinLlmGenerationsSafetyScoreRepresentation__selections, opaque: EinsteinLlmGenerationsSafetyScoreRepresentation__opaque, } = select$o();
1419
+ const select$z = function EinsteinLlmGenerationItemRepresentationSelect() {
1420
+ const { selections: EinsteinLlmGenerationsContentQualityRepresentation__selections, opaque: EinsteinLlmGenerationsContentQualityRepresentation__opaque, } = select$B();
1421
+ const { selections: EinsteinLlmGenerationsSafetyScoreRepresentation__selections, opaque: EinsteinLlmGenerationsSafetyScoreRepresentation__opaque, } = select$A();
1422
1422
  return {
1423
1423
  kind: 'Fragment',
1424
- version: VERSION$f,
1424
+ version: VERSION$k,
1425
1425
  private: [],
1426
1426
  selections: [
1427
1427
  {
@@ -1458,7 +1458,7 @@ const select$n = function EinsteinLlmGenerationItemRepresentationSelect() {
1458
1458
  ]
1459
1459
  };
1460
1460
  };
1461
- function equals$f(existing, incoming) {
1461
+ function equals$k(existing, incoming) {
1462
1462
  const existing_isSummarized = existing.isSummarized;
1463
1463
  const incoming_isSummarized = incoming.isSummarized;
1464
1464
  // if at least one of these optionals is defined
@@ -1499,7 +1499,7 @@ function equals$f(existing, incoming) {
1499
1499
  if (!(existing_contentQualityRepresentation === incoming_contentQualityRepresentation
1500
1500
  || (existing_contentQualityRepresentation != null &&
1501
1501
  incoming_contentQualityRepresentation != null &&
1502
- equals$h(existing_contentQualityRepresentation, incoming_contentQualityRepresentation)))) {
1502
+ equals$m(existing_contentQualityRepresentation, incoming_contentQualityRepresentation)))) {
1503
1503
  return false;
1504
1504
  }
1505
1505
  }
@@ -1515,15 +1515,15 @@ function equals$f(existing, incoming) {
1515
1515
  if (!(existing_safetyScoreRepresentation === incoming_safetyScoreRepresentation
1516
1516
  || (existing_safetyScoreRepresentation != null &&
1517
1517
  incoming_safetyScoreRepresentation != null &&
1518
- equals$g(existing_safetyScoreRepresentation, incoming_safetyScoreRepresentation)))) {
1518
+ equals$l(existing_safetyScoreRepresentation, incoming_safetyScoreRepresentation)))) {
1519
1519
  return false;
1520
1520
  }
1521
1521
  }
1522
1522
  return true;
1523
1523
  }
1524
1524
 
1525
- const VERSION$e = "4656c961c9d093a9e206c1db7d4de0b0";
1526
- function validate$h(obj, path = 'WrappedMap') {
1525
+ const VERSION$j = "379fd960d1a0118f506f458ab2c8dd7e";
1526
+ function validate$p(obj, path = 'WrappedMap') {
1527
1527
  const v_error = (() => {
1528
1528
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1529
1529
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -1538,25 +1538,34 @@ function validate$h(obj, path = 'WrappedMap') {
1538
1538
  const key = obj_wrappedMap_keys[i];
1539
1539
  const obj_wrappedMap_prop = obj_wrappedMap[key];
1540
1540
  const path_wrappedMap_prop = path_wrappedMap + '["' + key + '"]';
1541
- if (typeof obj_wrappedMap_prop !== 'object' || ArrayIsArray(obj_wrappedMap_prop) || obj_wrappedMap_prop === null) {
1542
- return new TypeError('Expected "object" but received "' + typeof obj_wrappedMap_prop + '" (at "' + path_wrappedMap_prop + '")');
1541
+ if (obj_wrappedMap_prop === undefined) {
1542
+ return new TypeError('Expected "defined" but received "' + typeof obj_wrappedMap_prop + '" (at "' + path_wrappedMap_prop + '")');
1543
1543
  }
1544
1544
  }
1545
1545
  })();
1546
1546
  return v_error === undefined ? null : v_error;
1547
1547
  }
1548
- const select$m = function WrappedMapSelect() {
1548
+ const select$y = function WrappedMapSelect() {
1549
1549
  return {
1550
1550
  kind: 'Fragment',
1551
- version: VERSION$e,
1551
+ version: VERSION$j,
1552
1552
  private: [],
1553
- selections: []
1553
+ selections: [
1554
+ {
1555
+ name: 'wrappedMap',
1556
+ kind: 'Object',
1557
+ // any
1558
+ }
1559
+ ]
1554
1560
  };
1555
1561
  };
1556
- function equals$e(existing, incoming) {
1562
+ function equals$j(existing, incoming) {
1557
1563
  const existing_wrappedMap = existing.wrappedMap;
1558
1564
  const incoming_wrappedMap = incoming.wrappedMap;
1559
1565
  const equals_wrappedMap_props = equalsObject(existing_wrappedMap, incoming_wrappedMap, (existing_wrappedMap_prop, incoming_wrappedMap_prop) => {
1566
+ if (JSONStringify(incoming_wrappedMap_prop) !== JSONStringify(existing_wrappedMap_prop)) {
1567
+ return false;
1568
+ }
1560
1569
  });
1561
1570
  if (equals_wrappedMap_props === false) {
1562
1571
  return false;
@@ -1564,9 +1573,9 @@ function equals$e(existing, incoming) {
1564
1573
  return true;
1565
1574
  }
1566
1575
 
1567
- const TTL$5 = 100;
1568
- const VERSION$d = "d8abd72a42e842b253da1c38954dafbc";
1569
- function validate$g(obj, path = 'EinsteinLlmGenerationsRepresentation') {
1576
+ const TTL$8 = 100;
1577
+ const VERSION$i = "d8abd72a42e842b253da1c38954dafbc";
1578
+ function validate$o(obj, path = 'EinsteinLlmGenerationsRepresentation') {
1570
1579
  const v_error = (() => {
1571
1580
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1572
1581
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -1579,7 +1588,7 @@ function validate$g(obj, path = 'EinsteinLlmGenerationsRepresentation') {
1579
1588
  for (let i = 0; i < obj_generations.length; i++) {
1580
1589
  const obj_generations_item = obj_generations[i];
1581
1590
  const path_generations_item = path_generations + '[' + i + ']';
1582
- const referencepath_generations_itemValidationError = validate$i(obj_generations_item, path_generations_item);
1591
+ const referencepath_generations_itemValidationError = validate$q(obj_generations_item, path_generations_item);
1583
1592
  if (referencepath_generations_itemValidationError !== null) {
1584
1593
  let message = 'Object doesn\'t match EinsteinLlmGenerationItemRepresentation (at "' + path_generations_item + '")\n';
1585
1594
  message += referencepath_generations_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -1590,7 +1599,7 @@ function validate$g(obj, path = 'EinsteinLlmGenerationsRepresentation') {
1590
1599
  const path_parameters = path + '.parameters';
1591
1600
  let obj_parameters_union0 = null;
1592
1601
  const obj_parameters_union0_error = (() => {
1593
- const referencepath_parametersValidationError = validate$h(obj_parameters, path_parameters);
1602
+ const referencepath_parametersValidationError = validate$p(obj_parameters, path_parameters);
1594
1603
  if (referencepath_parametersValidationError !== null) {
1595
1604
  let message = 'Object doesn\'t match WrappedMap (at "' + path_parameters + '")\n';
1596
1605
  message += referencepath_parametersValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -1649,25 +1658,25 @@ function validate$g(obj, path = 'EinsteinLlmGenerationsRepresentation') {
1649
1658
  })();
1650
1659
  return v_error === undefined ? null : v_error;
1651
1660
  }
1652
- const RepresentationType$5 = 'EinsteinLlmGenerationsRepresentation';
1653
- function keyBuilder$8(luvio, config) {
1654
- return keyPrefix + '::' + RepresentationType$5 + ':' + config.requestId;
1661
+ const RepresentationType$8 = 'EinsteinLlmGenerationsRepresentation';
1662
+ function keyBuilder$k(luvio, config) {
1663
+ return keyPrefix + '::' + RepresentationType$8 + ':' + config.requestId;
1655
1664
  }
1656
1665
  function keyBuilderFromType$2(luvio, object) {
1657
1666
  const keyParams = {
1658
1667
  requestId: object.requestId
1659
1668
  };
1660
- return keyBuilder$8(luvio, keyParams);
1669
+ return keyBuilder$k(luvio, keyParams);
1661
1670
  }
1662
- function normalize$5(input, existing, path, luvio, store, timestamp) {
1671
+ function normalize$8(input, existing, path, luvio, store, timestamp) {
1663
1672
  return input;
1664
1673
  }
1665
- const select$l = function EinsteinLlmGenerationsRepresentationSelect() {
1666
- const { selections: EinsteinLlmGenerationItemRepresentation__selections, opaque: EinsteinLlmGenerationItemRepresentation__opaque, } = select$n();
1667
- const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$m();
1674
+ const select$x = function EinsteinLlmGenerationsRepresentationSelect() {
1675
+ const { selections: EinsteinLlmGenerationItemRepresentation__selections, opaque: EinsteinLlmGenerationItemRepresentation__opaque, } = select$z();
1676
+ const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$y();
1668
1677
  return {
1669
1678
  kind: 'Fragment',
1670
- version: VERSION$d,
1679
+ version: VERSION$i,
1671
1680
  private: [],
1672
1681
  selections: [
1673
1682
  {
@@ -1693,7 +1702,7 @@ const select$l = function EinsteinLlmGenerationsRepresentationSelect() {
1693
1702
  ]
1694
1703
  };
1695
1704
  };
1696
- function equals$d(existing, incoming) {
1705
+ function equals$i(existing, incoming) {
1697
1706
  const existing_requestId = existing.requestId;
1698
1707
  const incoming_requestId = incoming.requestId;
1699
1708
  if (!(existing_requestId === incoming_requestId)) {
@@ -1702,7 +1711,7 @@ function equals$d(existing, incoming) {
1702
1711
  const existing_generations = existing.generations;
1703
1712
  const incoming_generations = incoming.generations;
1704
1713
  const equals_generations_items = equalsArray(existing_generations, incoming_generations, (existing_generations_item, incoming_generations_item) => {
1705
- if (!(equals$f(existing_generations_item, incoming_generations_item))) {
1714
+ if (!(equals$k(existing_generations_item, incoming_generations_item))) {
1706
1715
  return false;
1707
1716
  }
1708
1717
  });
@@ -1714,7 +1723,7 @@ function equals$d(existing, incoming) {
1714
1723
  if (!(existing_parameters === incoming_parameters
1715
1724
  || (existing_parameters != null &&
1716
1725
  incoming_parameters != null &&
1717
- equals$e(existing_parameters, incoming_parameters)))) {
1726
+ equals$j(existing_parameters, incoming_parameters)))) {
1718
1727
  return false;
1719
1728
  }
1720
1729
  const existing_prompt = existing.prompt;
@@ -1724,41 +1733,41 @@ function equals$d(existing, incoming) {
1724
1733
  }
1725
1734
  return true;
1726
1735
  }
1727
- const ingest$5 = function EinsteinLlmGenerationsRepresentationIngest(input, path, luvio, store, timestamp) {
1736
+ const ingest$8 = function EinsteinLlmGenerationsRepresentationIngest(input, path, luvio, store, timestamp) {
1728
1737
  if (process.env.NODE_ENV !== 'production') {
1729
- const validateError = validate$g(input);
1738
+ const validateError = validate$o(input);
1730
1739
  if (validateError !== null) {
1731
1740
  throw validateError;
1732
1741
  }
1733
1742
  }
1734
1743
  const key = keyBuilderFromType$2(luvio, input);
1735
- const ttlToUse = TTL$5;
1736
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$5, "EinsteinLLM", VERSION$d, RepresentationType$5, equals$d);
1744
+ const ttlToUse = TTL$8;
1745
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$8, "EinsteinLLM", VERSION$i, RepresentationType$8, equals$i);
1737
1746
  return createLink(key);
1738
1747
  };
1739
- function getTypeCacheKeys$5(rootKeySet, luvio, input, fullPathFactory) {
1748
+ function getTypeCacheKeys$8(rootKeySet, luvio, input, fullPathFactory) {
1740
1749
  // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
1741
1750
  const rootKey = keyBuilderFromType$2(luvio, input);
1742
1751
  rootKeySet.set(rootKey, {
1743
1752
  namespace: keyPrefix,
1744
- representationName: RepresentationType$5,
1753
+ representationName: RepresentationType$8,
1745
1754
  mergeable: false
1746
1755
  });
1747
1756
  }
1748
1757
 
1749
- function select$k(luvio, params) {
1750
- return select$l();
1758
+ function select$w(luvio, params) {
1759
+ return select$x();
1751
1760
  }
1752
- function getResponseCacheKeys$7(storeKeyMap, luvio, resourceParams, response) {
1753
- getTypeCacheKeys$5(storeKeyMap, luvio, response);
1761
+ function getResponseCacheKeys$e(storeKeyMap, luvio, resourceParams, response) {
1762
+ getTypeCacheKeys$8(storeKeyMap, luvio, response);
1754
1763
  }
1755
- function ingestSuccess$7(luvio, resourceParams, response) {
1764
+ function ingestSuccess$e(luvio, resourceParams, response) {
1756
1765
  const { body } = response;
1757
1766
  const key = keyBuilderFromType$2(luvio, body);
1758
- luvio.storeIngest(key, ingest$5, body);
1767
+ luvio.storeIngest(key, ingest$8, body);
1759
1768
  const snapshot = luvio.storeLookup({
1760
1769
  recordId: key,
1761
- node: select$k(),
1770
+ node: select$w(),
1762
1771
  variables: {},
1763
1772
  });
1764
1773
  if (process.env.NODE_ENV !== 'production') {
@@ -1769,7 +1778,7 @@ function ingestSuccess$7(luvio, resourceParams, response) {
1769
1778
  deepFreeze(snapshot.data);
1770
1779
  return snapshot;
1771
1780
  }
1772
- function createResourceRequest$7(config) {
1781
+ function createResourceRequest$e(config) {
1773
1782
  const headers = {};
1774
1783
  return {
1775
1784
  baseUri: '/services/data/v65.0',
@@ -1783,45 +1792,45 @@ function createResourceRequest$7(config) {
1783
1792
  };
1784
1793
  }
1785
1794
 
1786
- const adapterName$7 = 'createGenerations';
1795
+ const adapterName$e = 'createGenerations';
1787
1796
  const createGenerations_ConfigPropertyMetadata = [
1788
1797
  generateParamConfigMetadata('generationsInput', true, 2 /* Body */, 4 /* Unsupported */),
1789
1798
  ];
1790
- const createGenerations_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$7, createGenerations_ConfigPropertyMetadata);
1791
- const createResourceParams$7 = /*#__PURE__*/ createResourceParams$a(createGenerations_ConfigPropertyMetadata);
1792
- function typeCheckConfig$7(untrustedConfig) {
1799
+ const createGenerations_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$e, createGenerations_ConfigPropertyMetadata);
1800
+ const createResourceParams$e = /*#__PURE__*/ createResourceParams$h(createGenerations_ConfigPropertyMetadata);
1801
+ function typeCheckConfig$e(untrustedConfig) {
1793
1802
  const config = {};
1794
1803
  const untrustedConfig_generationsInput = untrustedConfig.generationsInput;
1795
- const referenceEinsteinLlmGenerationsInputRepresentationValidationError = validate$l(untrustedConfig_generationsInput);
1804
+ const referenceEinsteinLlmGenerationsInputRepresentationValidationError = validate$t(untrustedConfig_generationsInput);
1796
1805
  if (referenceEinsteinLlmGenerationsInputRepresentationValidationError === null) {
1797
1806
  config.generationsInput = untrustedConfig_generationsInput;
1798
1807
  }
1799
1808
  return config;
1800
1809
  }
1801
- function validateAdapterConfig$7(untrustedConfig, configPropertyNames) {
1810
+ function validateAdapterConfig$e(untrustedConfig, configPropertyNames) {
1802
1811
  if (!untrustedIsObject(untrustedConfig)) {
1803
1812
  return null;
1804
1813
  }
1805
1814
  if (process.env.NODE_ENV !== 'production') {
1806
1815
  validateConfig(untrustedConfig, configPropertyNames);
1807
1816
  }
1808
- const config = typeCheckConfig$7(untrustedConfig);
1817
+ const config = typeCheckConfig$e(untrustedConfig);
1809
1818
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
1810
1819
  return null;
1811
1820
  }
1812
1821
  return config;
1813
1822
  }
1814
- function buildNetworkSnapshot$7(luvio, config, options) {
1815
- const resourceParams = createResourceParams$7(config);
1816
- const request = createResourceRequest$7(resourceParams);
1823
+ function buildNetworkSnapshot$e(luvio, config, options) {
1824
+ const resourceParams = createResourceParams$e(config);
1825
+ const request = createResourceRequest$e(resourceParams);
1817
1826
  return luvio.dispatchResourceRequest(request, options)
1818
1827
  .then((response) => {
1819
1828
  return luvio.handleSuccessResponse(() => {
1820
- const snapshot = ingestSuccess$7(luvio, resourceParams, response);
1829
+ const snapshot = ingestSuccess$e(luvio, resourceParams, response);
1821
1830
  return luvio.storeBroadcast().then(() => snapshot);
1822
1831
  }, () => {
1823
1832
  const cache = new StoreKeyMap();
1824
- getResponseCacheKeys$7(cache, luvio, resourceParams, response.body);
1833
+ getResponseCacheKeys$e(cache, luvio, resourceParams, response.body);
1825
1834
  return cache;
1826
1835
  });
1827
1836
  }, (response) => {
@@ -1831,16 +1840,16 @@ function buildNetworkSnapshot$7(luvio, config, options) {
1831
1840
  }
1832
1841
  const createGenerationsAdapterFactory = (luvio) => {
1833
1842
  return function createGenerations(untrustedConfig) {
1834
- const config = validateAdapterConfig$7(untrustedConfig, createGenerations_ConfigPropertyNames);
1843
+ const config = validateAdapterConfig$e(untrustedConfig, createGenerations_ConfigPropertyNames);
1835
1844
  // Invalid or incomplete config
1836
1845
  if (config === null) {
1837
1846
  throw new Error('Invalid config for "createGenerations"');
1838
1847
  }
1839
- return buildNetworkSnapshot$7(luvio, config);
1848
+ return buildNetworkSnapshot$e(luvio, config);
1840
1849
  };
1841
1850
  };
1842
1851
 
1843
- function validate$f(obj, path = 'WrappedValueMap') {
1852
+ function validate$n(obj, path = 'WrappedValueMap') {
1844
1853
  const v_error = (() => {
1845
1854
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1846
1855
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -1863,7 +1872,7 @@ function validate$f(obj, path = 'WrappedValueMap') {
1863
1872
  return v_error === undefined ? null : v_error;
1864
1873
  }
1865
1874
 
1866
- function validate$e(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresentation') {
1875
+ function validate$m(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresentation') {
1867
1876
  const v_error = (() => {
1868
1877
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1869
1878
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -1871,7 +1880,7 @@ function validate$e(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresent
1871
1880
  if (obj.additionalConfig !== undefined) {
1872
1881
  const obj_additionalConfig = obj.additionalConfig;
1873
1882
  const path_additionalConfig = path + '.additionalConfig';
1874
- const referencepath_additionalConfigValidationError = validate$m(obj_additionalConfig, path_additionalConfig);
1883
+ const referencepath_additionalConfigValidationError = validate$u(obj_additionalConfig, path_additionalConfig);
1875
1884
  if (referencepath_additionalConfigValidationError !== null) {
1876
1885
  let message = 'Object doesn\'t match EinsteinLlmAdditionalConfigInputRepresentation (at "' + path_additionalConfig + '")\n';
1877
1886
  message += referencepath_additionalConfigValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -1880,7 +1889,7 @@ function validate$e(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresent
1880
1889
  }
1881
1890
  const obj_inputParams = obj.inputParams;
1882
1891
  const path_inputParams = path + '.inputParams';
1883
- const referencepath_inputParamsValidationError = validate$f(obj_inputParams, path_inputParams);
1892
+ const referencepath_inputParamsValidationError = validate$n(obj_inputParams, path_inputParams);
1884
1893
  if (referencepath_inputParamsValidationError !== null) {
1885
1894
  let message = 'Object doesn\'t match WrappedValueMap (at "' + path_inputParams + '")\n';
1886
1895
  message += referencepath_inputParamsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -1916,8 +1925,246 @@ function validate$e(obj, path = 'EinsteinPromptTemplateGenerationsInputRepresent
1916
1925
  return v_error === undefined ? null : v_error;
1917
1926
  }
1918
1927
 
1919
- const VERSION$c = "f62ac44b024b123f079b57f349e05230";
1920
- function validate$d(obj, path = 'EinsteinPromptTemplateAttachmentExclusionInfoRepresentation') {
1928
+ const VERSION$h = "63584d83290e21bdff26b1bef3db119c";
1929
+ function validate$l(obj, path = 'EinsteinLlmGenerationGenAiCitedReferenceRepresentation') {
1930
+ const v_error = (() => {
1931
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1932
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
1933
+ }
1934
+ if (obj.citationLocations !== undefined) {
1935
+ const obj_citationLocations = obj.citationLocations;
1936
+ const path_citationLocations = path + '.citationLocations';
1937
+ if (!ArrayIsArray(obj_citationLocations)) {
1938
+ return new TypeError('Expected "array" but received "' + typeof obj_citationLocations + '" (at "' + path_citationLocations + '")');
1939
+ }
1940
+ for (let i = 0; i < obj_citationLocations.length; i++) {
1941
+ const obj_citationLocations_item = obj_citationLocations[i];
1942
+ const path_citationLocations_item = path_citationLocations + '[' + i + ']';
1943
+ if (typeof obj_citationLocations_item !== 'number' || (typeof obj_citationLocations_item === 'number' && Math.floor(obj_citationLocations_item) !== obj_citationLocations_item)) {
1944
+ return new TypeError('Expected "integer" but received "' + typeof obj_citationLocations_item + '" (at "' + path_citationLocations_item + '")');
1945
+ }
1946
+ }
1947
+ }
1948
+ if (obj.claims !== undefined) {
1949
+ const obj_claims = obj.claims;
1950
+ const path_claims = path + '.claims';
1951
+ if (!ArrayIsArray(obj_claims)) {
1952
+ return new TypeError('Expected "array" but received "' + typeof obj_claims + '" (at "' + path_claims + '")');
1953
+ }
1954
+ for (let i = 0; i < obj_claims.length; i++) {
1955
+ const obj_claims_item = obj_claims[i];
1956
+ const path_claims_item = path_claims + '[' + i + ']';
1957
+ if (typeof obj_claims_item !== 'string') {
1958
+ return new TypeError('Expected "string" but received "' + typeof obj_claims_item + '" (at "' + path_claims_item + '")');
1959
+ }
1960
+ }
1961
+ }
1962
+ if (obj.link !== undefined) {
1963
+ const obj_link = obj.link;
1964
+ const path_link = path + '.link';
1965
+ if (typeof obj_link !== 'string') {
1966
+ return new TypeError('Expected "string" but received "' + typeof obj_link + '" (at "' + path_link + '")');
1967
+ }
1968
+ }
1969
+ if (obj.sourceObjectApiName !== undefined) {
1970
+ const obj_sourceObjectApiName = obj.sourceObjectApiName;
1971
+ const path_sourceObjectApiName = path + '.sourceObjectApiName';
1972
+ if (typeof obj_sourceObjectApiName !== 'string') {
1973
+ return new TypeError('Expected "string" but received "' + typeof obj_sourceObjectApiName + '" (at "' + path_sourceObjectApiName + '")');
1974
+ }
1975
+ }
1976
+ if (obj.sourceObjectRecordId !== undefined) {
1977
+ const obj_sourceObjectRecordId = obj.sourceObjectRecordId;
1978
+ const path_sourceObjectRecordId = path + '.sourceObjectRecordId';
1979
+ if (typeof obj_sourceObjectRecordId !== 'string') {
1980
+ return new TypeError('Expected "string" but received "' + typeof obj_sourceObjectRecordId + '" (at "' + path_sourceObjectRecordId + '")');
1981
+ }
1982
+ }
1983
+ })();
1984
+ return v_error === undefined ? null : v_error;
1985
+ }
1986
+ const select$v = function EinsteinLlmGenerationGenAiCitedReferenceRepresentationSelect() {
1987
+ return {
1988
+ kind: 'Fragment',
1989
+ version: VERSION$h,
1990
+ private: [],
1991
+ selections: [
1992
+ {
1993
+ name: 'citationLocations',
1994
+ kind: 'Scalar',
1995
+ plural: true,
1996
+ required: false
1997
+ },
1998
+ {
1999
+ name: 'claims',
2000
+ kind: 'Scalar',
2001
+ plural: true,
2002
+ required: false
2003
+ },
2004
+ {
2005
+ name: 'link',
2006
+ kind: 'Scalar',
2007
+ required: false
2008
+ },
2009
+ {
2010
+ name: 'sourceObjectApiName',
2011
+ kind: 'Scalar',
2012
+ required: false
2013
+ },
2014
+ {
2015
+ name: 'sourceObjectRecordId',
2016
+ kind: 'Scalar',
2017
+ required: false
2018
+ }
2019
+ ]
2020
+ };
2021
+ };
2022
+ function equals$h(existing, incoming) {
2023
+ const existing_link = existing.link;
2024
+ const incoming_link = incoming.link;
2025
+ // if at least one of these optionals is defined
2026
+ if (existing_link !== undefined || incoming_link !== undefined) {
2027
+ // if one of these is not defined we know the other is defined and therefore
2028
+ // not equal
2029
+ if (existing_link === undefined || incoming_link === undefined) {
2030
+ return false;
2031
+ }
2032
+ if (!(existing_link === incoming_link)) {
2033
+ return false;
2034
+ }
2035
+ }
2036
+ const existing_sourceObjectApiName = existing.sourceObjectApiName;
2037
+ const incoming_sourceObjectApiName = incoming.sourceObjectApiName;
2038
+ // if at least one of these optionals is defined
2039
+ if (existing_sourceObjectApiName !== undefined || incoming_sourceObjectApiName !== undefined) {
2040
+ // if one of these is not defined we know the other is defined and therefore
2041
+ // not equal
2042
+ if (existing_sourceObjectApiName === undefined || incoming_sourceObjectApiName === undefined) {
2043
+ return false;
2044
+ }
2045
+ if (!(existing_sourceObjectApiName === incoming_sourceObjectApiName)) {
2046
+ return false;
2047
+ }
2048
+ }
2049
+ const existing_sourceObjectRecordId = existing.sourceObjectRecordId;
2050
+ const incoming_sourceObjectRecordId = incoming.sourceObjectRecordId;
2051
+ // if at least one of these optionals is defined
2052
+ if (existing_sourceObjectRecordId !== undefined || incoming_sourceObjectRecordId !== undefined) {
2053
+ // if one of these is not defined we know the other is defined and therefore
2054
+ // not equal
2055
+ if (existing_sourceObjectRecordId === undefined || incoming_sourceObjectRecordId === undefined) {
2056
+ return false;
2057
+ }
2058
+ if (!(existing_sourceObjectRecordId === incoming_sourceObjectRecordId)) {
2059
+ return false;
2060
+ }
2061
+ }
2062
+ const existing_citationLocations = existing.citationLocations;
2063
+ const incoming_citationLocations = incoming.citationLocations;
2064
+ // if at least one of these optionals is defined
2065
+ if (existing_citationLocations !== undefined || incoming_citationLocations !== undefined) {
2066
+ // if one of these is not defined we know the other is defined and therefore
2067
+ // not equal
2068
+ if (existing_citationLocations === undefined || incoming_citationLocations === undefined) {
2069
+ return false;
2070
+ }
2071
+ const equals_citationLocations_items = equalsArray(existing_citationLocations, incoming_citationLocations, (existing_citationLocations_item, incoming_citationLocations_item) => {
2072
+ if (!(existing_citationLocations_item === incoming_citationLocations_item)) {
2073
+ return false;
2074
+ }
2075
+ });
2076
+ if (equals_citationLocations_items === false) {
2077
+ return false;
2078
+ }
2079
+ }
2080
+ const existing_claims = existing.claims;
2081
+ const incoming_claims = incoming.claims;
2082
+ // if at least one of these optionals is defined
2083
+ if (existing_claims !== undefined || incoming_claims !== undefined) {
2084
+ // if one of these is not defined we know the other is defined and therefore
2085
+ // not equal
2086
+ if (existing_claims === undefined || incoming_claims === undefined) {
2087
+ return false;
2088
+ }
2089
+ const equals_claims_items = equalsArray(existing_claims, incoming_claims, (existing_claims_item, incoming_claims_item) => {
2090
+ if (!(existing_claims_item === incoming_claims_item)) {
2091
+ return false;
2092
+ }
2093
+ });
2094
+ if (equals_claims_items === false) {
2095
+ return false;
2096
+ }
2097
+ }
2098
+ return true;
2099
+ }
2100
+
2101
+ const VERSION$g = "bcc0ea08323732f4187dd2b9f70fea6c";
2102
+ function validate$k(obj, path = 'EinsteinLlmGenerationCitationRepresentation') {
2103
+ const v_error = (() => {
2104
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2105
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
2106
+ }
2107
+ if (obj.citedReferences !== undefined) {
2108
+ const obj_citedReferences = obj.citedReferences;
2109
+ const path_citedReferences = path + '.citedReferences';
2110
+ if (!ArrayIsArray(obj_citedReferences)) {
2111
+ return new TypeError('Expected "array" but received "' + typeof obj_citedReferences + '" (at "' + path_citedReferences + '")');
2112
+ }
2113
+ for (let i = 0; i < obj_citedReferences.length; i++) {
2114
+ const obj_citedReferences_item = obj_citedReferences[i];
2115
+ const path_citedReferences_item = path_citedReferences + '[' + i + ']';
2116
+ const referencepath_citedReferences_itemValidationError = validate$l(obj_citedReferences_item, path_citedReferences_item);
2117
+ if (referencepath_citedReferences_itemValidationError !== null) {
2118
+ let message = 'Object doesn\'t match EinsteinLlmGenerationGenAiCitedReferenceRepresentation (at "' + path_citedReferences_item + '")\n';
2119
+ message += referencepath_citedReferences_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
2120
+ return new TypeError(message);
2121
+ }
2122
+ }
2123
+ }
2124
+ })();
2125
+ return v_error === undefined ? null : v_error;
2126
+ }
2127
+ const select$u = function EinsteinLlmGenerationCitationRepresentationSelect() {
2128
+ const { selections: EinsteinLlmGenerationGenAiCitedReferenceRepresentation__selections, opaque: EinsteinLlmGenerationGenAiCitedReferenceRepresentation__opaque, } = select$v();
2129
+ return {
2130
+ kind: 'Fragment',
2131
+ version: VERSION$g,
2132
+ private: [],
2133
+ selections: [
2134
+ {
2135
+ name: 'citedReferences',
2136
+ kind: 'Object',
2137
+ plural: true,
2138
+ selections: EinsteinLlmGenerationGenAiCitedReferenceRepresentation__selections,
2139
+ required: false
2140
+ }
2141
+ ]
2142
+ };
2143
+ };
2144
+ function equals$g(existing, incoming) {
2145
+ const existing_citedReferences = existing.citedReferences;
2146
+ const incoming_citedReferences = incoming.citedReferences;
2147
+ // if at least one of these optionals is defined
2148
+ if (existing_citedReferences !== undefined || incoming_citedReferences !== undefined) {
2149
+ // if one of these is not defined we know the other is defined and therefore
2150
+ // not equal
2151
+ if (existing_citedReferences === undefined || incoming_citedReferences === undefined) {
2152
+ return false;
2153
+ }
2154
+ const equals_citedReferences_items = equalsArray(existing_citedReferences, incoming_citedReferences, (existing_citedReferences_item, incoming_citedReferences_item) => {
2155
+ if (!(equals$h(existing_citedReferences_item, incoming_citedReferences_item))) {
2156
+ return false;
2157
+ }
2158
+ });
2159
+ if (equals_citedReferences_items === false) {
2160
+ return false;
2161
+ }
2162
+ }
2163
+ return true;
2164
+ }
2165
+
2166
+ const VERSION$f = "f62ac44b024b123f079b57f349e05230";
2167
+ function validate$j(obj, path = 'EinsteinPromptTemplateAttachmentExclusionInfoRepresentation') {
1921
2168
  const v_error = (() => {
1922
2169
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1923
2170
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -1935,10 +2182,10 @@ function validate$d(obj, path = 'EinsteinPromptTemplateAttachmentExclusionInfoRe
1935
2182
  })();
1936
2183
  return v_error === undefined ? null : v_error;
1937
2184
  }
1938
- const select$j = function EinsteinPromptTemplateAttachmentExclusionInfoRepresentationSelect() {
2185
+ const select$t = function EinsteinPromptTemplateAttachmentExclusionInfoRepresentationSelect() {
1939
2186
  return {
1940
2187
  kind: 'Fragment',
1941
- version: VERSION$c,
2188
+ version: VERSION$f,
1942
2189
  private: [],
1943
2190
  selections: [
1944
2191
  {
@@ -1952,7 +2199,7 @@ const select$j = function EinsteinPromptTemplateAttachmentExclusionInfoRepresent
1952
2199
  ]
1953
2200
  };
1954
2201
  };
1955
- function equals$c(existing, incoming) {
2202
+ function equals$f(existing, incoming) {
1956
2203
  const existing_isExcluded = existing.isExcluded;
1957
2204
  const incoming_isExcluded = incoming.isExcluded;
1958
2205
  if (!(existing_isExcluded === incoming_isExcluded)) {
@@ -1966,8 +2213,8 @@ function equals$c(existing, incoming) {
1966
2213
  return true;
1967
2214
  }
1968
2215
 
1969
- const VERSION$b = "b85a5621c60125d9f1644af130f67680";
1970
- function validate$c(obj, path = 'EinsteinPromptTemplateAttachmentRepresentation') {
2216
+ const VERSION$e = "b85a5621c60125d9f1644af130f67680";
2217
+ function validate$i(obj, path = 'EinsteinPromptTemplateAttachmentRepresentation') {
1971
2218
  const v_error = (() => {
1972
2219
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1973
2220
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -1975,7 +2222,7 @@ function validate$c(obj, path = 'EinsteinPromptTemplateAttachmentRepresentation'
1975
2222
  if (obj.exclusionInfo !== undefined) {
1976
2223
  const obj_exclusionInfo = obj.exclusionInfo;
1977
2224
  const path_exclusionInfo = path + '.exclusionInfo';
1978
- const referencepath_exclusionInfoValidationError = validate$d(obj_exclusionInfo, path_exclusionInfo);
2225
+ const referencepath_exclusionInfoValidationError = validate$j(obj_exclusionInfo, path_exclusionInfo);
1979
2226
  if (referencepath_exclusionInfoValidationError !== null) {
1980
2227
  let message = 'Object doesn\'t match EinsteinPromptTemplateAttachmentExclusionInfoRepresentation (at "' + path_exclusionInfo + '")\n';
1981
2228
  message += referencepath_exclusionInfoValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2012,11 +2259,11 @@ function validate$c(obj, path = 'EinsteinPromptTemplateAttachmentRepresentation'
2012
2259
  })();
2013
2260
  return v_error === undefined ? null : v_error;
2014
2261
  }
2015
- const select$i = function EinsteinPromptTemplateAttachmentRepresentationSelect() {
2016
- const { selections: EinsteinPromptTemplateAttachmentExclusionInfoRepresentation__selections, opaque: EinsteinPromptTemplateAttachmentExclusionInfoRepresentation__opaque, } = select$j();
2262
+ const select$s = function EinsteinPromptTemplateAttachmentRepresentationSelect() {
2263
+ const { selections: EinsteinPromptTemplateAttachmentExclusionInfoRepresentation__selections, opaque: EinsteinPromptTemplateAttachmentExclusionInfoRepresentation__opaque, } = select$t();
2017
2264
  return {
2018
2265
  kind: 'Fragment',
2019
- version: VERSION$b,
2266
+ version: VERSION$e,
2020
2267
  private: [],
2021
2268
  selections: [
2022
2269
  {
@@ -2049,7 +2296,7 @@ const select$i = function EinsteinPromptTemplateAttachmentRepresentationSelect()
2049
2296
  ]
2050
2297
  };
2051
2298
  };
2052
- function equals$b(existing, incoming) {
2299
+ function equals$e(existing, incoming) {
2053
2300
  const existing_fileExtension = existing.fileExtension;
2054
2301
  const incoming_fileExtension = incoming.fileExtension;
2055
2302
  if (!(existing_fileExtension === incoming_fileExtension)) {
@@ -2092,15 +2339,15 @@ function equals$b(existing, incoming) {
2092
2339
  if (existing_exclusionInfo === undefined || incoming_exclusionInfo === undefined) {
2093
2340
  return false;
2094
2341
  }
2095
- if (!(equals$c(existing_exclusionInfo, incoming_exclusionInfo))) {
2342
+ if (!(equals$f(existing_exclusionInfo, incoming_exclusionInfo))) {
2096
2343
  return false;
2097
2344
  }
2098
2345
  }
2099
2346
  return true;
2100
2347
  }
2101
2348
 
2102
- const VERSION$a = "6458d624e5a1691821c764b6de0badb3";
2103
- function validate$b(obj, path = 'EinsteinPromptTemplateGenerationsErrorRepresentation') {
2349
+ const VERSION$d = "6458d624e5a1691821c764b6de0badb3";
2350
+ function validate$h(obj, path = 'EinsteinPromptTemplateGenerationsErrorRepresentation') {
2104
2351
  const v_error = (() => {
2105
2352
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2106
2353
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -2130,10 +2377,10 @@ function validate$b(obj, path = 'EinsteinPromptTemplateGenerationsErrorRepresent
2130
2377
  })();
2131
2378
  return v_error === undefined ? null : v_error;
2132
2379
  }
2133
- const select$h = function EinsteinPromptTemplateGenerationsErrorRepresentationSelect() {
2380
+ const select$r = function EinsteinPromptTemplateGenerationsErrorRepresentationSelect() {
2134
2381
  return {
2135
2382
  kind: 'Fragment',
2136
- version: VERSION$a,
2383
+ version: VERSION$d,
2137
2384
  private: [],
2138
2385
  selections: [
2139
2386
  {
@@ -2156,7 +2403,7 @@ const select$h = function EinsteinPromptTemplateGenerationsErrorRepresentationSe
2156
2403
  ]
2157
2404
  };
2158
2405
  };
2159
- function equals$a(existing, incoming) {
2406
+ function equals$d(existing, incoming) {
2160
2407
  const existing_errorMessage = existing.errorMessage;
2161
2408
  const incoming_errorMessage = incoming.errorMessage;
2162
2409
  if (!(existing_errorMessage === incoming_errorMessage)) {
@@ -2188,8 +2435,8 @@ function equals$a(existing, incoming) {
2188
2435
  return true;
2189
2436
  }
2190
2437
 
2191
- const VERSION$9 = "7c417ce44e4bc05dfcc454e6825590e8";
2192
- function validate$a(obj, path = 'EinsteinPromptTemplateMaskSettingsRepresentation') {
2438
+ const VERSION$c = "7c417ce44e4bc05dfcc454e6825590e8";
2439
+ function validate$g(obj, path = 'EinsteinPromptTemplateMaskSettingsRepresentation') {
2193
2440
  const v_error = (() => {
2194
2441
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2195
2442
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -2202,10 +2449,10 @@ function validate$a(obj, path = 'EinsteinPromptTemplateMaskSettingsRepresentatio
2202
2449
  })();
2203
2450
  return v_error === undefined ? null : v_error;
2204
2451
  }
2205
- const select$g = function EinsteinPromptTemplateMaskSettingsRepresentationSelect() {
2452
+ const select$q = function EinsteinPromptTemplateMaskSettingsRepresentationSelect() {
2206
2453
  return {
2207
2454
  kind: 'Fragment',
2208
- version: VERSION$9,
2455
+ version: VERSION$c,
2209
2456
  private: [],
2210
2457
  selections: [
2211
2458
  {
@@ -2215,7 +2462,7 @@ const select$g = function EinsteinPromptTemplateMaskSettingsRepresentationSelect
2215
2462
  ]
2216
2463
  };
2217
2464
  };
2218
- function equals$9(existing, incoming) {
2465
+ function equals$c(existing, incoming) {
2219
2466
  const existing_enableModeration = existing.enableModeration;
2220
2467
  const incoming_enableModeration = incoming.enableModeration;
2221
2468
  if (!(existing_enableModeration === incoming_enableModeration)) {
@@ -2224,8 +2471,8 @@ function equals$9(existing, incoming) {
2224
2471
  return true;
2225
2472
  }
2226
2473
 
2227
- const VERSION$8 = "92ad1abd0e2a60bc36941409cadda7e2";
2228
- function validate$9(obj, path = 'EinsteinPromptTemplateMaskContentRepresentation') {
2474
+ const VERSION$b = "92ad1abd0e2a60bc36941409cadda7e2";
2475
+ function validate$f(obj, path = 'EinsteinPromptTemplateMaskContentRepresentation') {
2229
2476
  const v_error = (() => {
2230
2477
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2231
2478
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -2240,7 +2487,7 @@ function validate$9(obj, path = 'EinsteinPromptTemplateMaskContentRepresentation
2240
2487
  const path_moderationSettings = path + '.moderationSettings';
2241
2488
  let obj_moderationSettings_union0 = null;
2242
2489
  const obj_moderationSettings_union0_error = (() => {
2243
- const referencepath_moderationSettingsValidationError = validate$a(obj_moderationSettings, path_moderationSettings);
2490
+ const referencepath_moderationSettingsValidationError = validate$g(obj_moderationSettings, path_moderationSettings);
2244
2491
  if (referencepath_moderationSettingsValidationError !== null) {
2245
2492
  let message = 'Object doesn\'t match EinsteinPromptTemplateMaskSettingsRepresentation (at "' + path_moderationSettings + '")\n';
2246
2493
  message += referencepath_moderationSettingsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2276,11 +2523,11 @@ function validate$9(obj, path = 'EinsteinPromptTemplateMaskContentRepresentation
2276
2523
  })();
2277
2524
  return v_error === undefined ? null : v_error;
2278
2525
  }
2279
- const select$f = function EinsteinPromptTemplateMaskContentRepresentationSelect() {
2280
- const { selections: EinsteinPromptTemplateMaskSettingsRepresentation__selections, opaque: EinsteinPromptTemplateMaskSettingsRepresentation__opaque, } = select$g();
2526
+ const select$p = function EinsteinPromptTemplateMaskContentRepresentationSelect() {
2527
+ const { selections: EinsteinPromptTemplateMaskSettingsRepresentation__selections, opaque: EinsteinPromptTemplateMaskSettingsRepresentation__opaque, } = select$q();
2281
2528
  return {
2282
2529
  kind: 'Fragment',
2283
- version: VERSION$8,
2530
+ version: VERSION$b,
2284
2531
  private: [],
2285
2532
  selections: [
2286
2533
  {
@@ -2302,7 +2549,7 @@ const select$f = function EinsteinPromptTemplateMaskContentRepresentationSelect(
2302
2549
  ]
2303
2550
  };
2304
2551
  };
2305
- function equals$8(existing, incoming) {
2552
+ function equals$b(existing, incoming) {
2306
2553
  const existing_content = existing.content;
2307
2554
  const incoming_content = incoming.content;
2308
2555
  if (!(existing_content === incoming_content)) {
@@ -2333,15 +2580,15 @@ function equals$8(existing, incoming) {
2333
2580
  if (!(existing_moderationSettings === incoming_moderationSettings
2334
2581
  || (existing_moderationSettings != null &&
2335
2582
  incoming_moderationSettings != null &&
2336
- equals$9(existing_moderationSettings, incoming_moderationSettings)))) {
2583
+ equals$c(existing_moderationSettings, incoming_moderationSettings)))) {
2337
2584
  return false;
2338
2585
  }
2339
2586
  }
2340
2587
  return true;
2341
2588
  }
2342
2589
 
2343
- const VERSION$7 = "507a815605f8d30ae9b52b0ec513d25e";
2344
- function validate$8(obj, path = 'EinsteinPromptTemplateMaskDataRepresentation') {
2590
+ const VERSION$a = "507a815605f8d30ae9b52b0ec513d25e";
2591
+ function validate$e(obj, path = 'EinsteinPromptTemplateMaskDataRepresentation') {
2345
2592
  const v_error = (() => {
2346
2593
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2347
2594
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -2371,10 +2618,10 @@ function validate$8(obj, path = 'EinsteinPromptTemplateMaskDataRepresentation')
2371
2618
  })();
2372
2619
  return v_error === undefined ? null : v_error;
2373
2620
  }
2374
- const select$e = function EinsteinPromptTemplateMaskDataRepresentationSelect() {
2621
+ const select$o = function EinsteinPromptTemplateMaskDataRepresentationSelect() {
2375
2622
  return {
2376
2623
  kind: 'Fragment',
2377
- version: VERSION$7,
2624
+ version: VERSION$a,
2378
2625
  private: [],
2379
2626
  selections: [
2380
2627
  {
@@ -2393,7 +2640,7 @@ const select$e = function EinsteinPromptTemplateMaskDataRepresentationSelect() {
2393
2640
  ]
2394
2641
  };
2395
2642
  };
2396
- function equals$7(existing, incoming) {
2643
+ function equals$a(existing, incoming) {
2397
2644
  const existing_originalValue = existing.originalValue;
2398
2645
  const incoming_originalValue = incoming.originalValue;
2399
2646
  if (!(existing_originalValue === incoming_originalValue)) {
@@ -2417,13 +2664,23 @@ function equals$7(existing, incoming) {
2417
2664
  return true;
2418
2665
  }
2419
2666
 
2420
- const TTL$4 = 100;
2421
- const VERSION$6 = "492c5045545dfbf96d7f660532a30499";
2422
- function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation') {
2667
+ const TTL$7 = 100;
2668
+ const VERSION$9 = "4f8799314eebcd45e3fca72dcdf7722d";
2669
+ function validate$d(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation') {
2423
2670
  const v_error = (() => {
2424
2671
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2425
2672
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
2426
2673
  }
2674
+ if (obj.citations !== undefined) {
2675
+ const obj_citations = obj.citations;
2676
+ const path_citations = path + '.citations';
2677
+ const referencepath_citationsValidationError = validate$k(obj_citations, path_citations);
2678
+ if (referencepath_citationsValidationError !== null) {
2679
+ let message = 'Object doesn\'t match EinsteinLlmGenerationCitationRepresentation (at "' + path_citations + '")\n';
2680
+ message += referencepath_citationsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
2681
+ return new TypeError(message);
2682
+ }
2683
+ }
2427
2684
  if (obj.fileData !== undefined) {
2428
2685
  const obj_fileData = obj.fileData;
2429
2686
  const path_fileData = path + '.fileData';
@@ -2433,7 +2690,7 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2433
2690
  for (let i = 0; i < obj_fileData.length; i++) {
2434
2691
  const obj_fileData_item = obj_fileData[i];
2435
2692
  const path_fileData_item = path_fileData + '[' + i + ']';
2436
- const referencepath_fileData_itemValidationError = validate$c(obj_fileData_item, path_fileData_item);
2693
+ const referencepath_fileData_itemValidationError = validate$i(obj_fileData_item, path_fileData_item);
2437
2694
  if (referencepath_fileData_itemValidationError !== null) {
2438
2695
  let message = 'Object doesn\'t match EinsteinPromptTemplateAttachmentRepresentation (at "' + path_fileData_item + '")\n';
2439
2696
  message += referencepath_fileData_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2450,7 +2707,7 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2450
2707
  for (let i = 0; i < obj_generationErrors.length; i++) {
2451
2708
  const obj_generationErrors_item = obj_generationErrors[i];
2452
2709
  const path_generationErrors_item = path_generationErrors + '[' + i + ']';
2453
- const referencepath_generationErrors_itemValidationError = validate$b(obj_generationErrors_item, path_generationErrors_item);
2710
+ const referencepath_generationErrors_itemValidationError = validate$h(obj_generationErrors_item, path_generationErrors_item);
2454
2711
  if (referencepath_generationErrors_itemValidationError !== null) {
2455
2712
  let message = 'Object doesn\'t match EinsteinPromptTemplateGenerationsErrorRepresentation (at "' + path_generationErrors_item + '")\n';
2456
2713
  message += referencepath_generationErrors_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2466,7 +2723,7 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2466
2723
  for (let i = 0; i < obj_generations.length; i++) {
2467
2724
  const obj_generations_item = obj_generations[i];
2468
2725
  const path_generations_item = path_generations + '[' + i + ']';
2469
- const referencepath_generations_itemValidationError = validate$i(obj_generations_item, path_generations_item);
2726
+ const referencepath_generations_itemValidationError = validate$q(obj_generations_item, path_generations_item);
2470
2727
  if (referencepath_generations_itemValidationError !== null) {
2471
2728
  let message = 'Object doesn\'t match EinsteinLlmGenerationItemRepresentation (at "' + path_generations_item + '")\n';
2472
2729
  message += referencepath_generations_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2493,7 +2750,7 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2493
2750
  const path_parameters = path + '.parameters';
2494
2751
  let obj_parameters_union0 = null;
2495
2752
  const obj_parameters_union0_error = (() => {
2496
- const referencepath_parametersValidationError = validate$h(obj_parameters, path_parameters);
2753
+ const referencepath_parametersValidationError = validate$p(obj_parameters, path_parameters);
2497
2754
  if (referencepath_parametersValidationError !== null) {
2498
2755
  let message = 'Object doesn\'t match WrappedMap (at "' + path_parameters + '")\n';
2499
2756
  message += referencepath_parametersValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2549,6 +2806,32 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2549
2806
  if (typeof obj_promptTemplateDevName !== 'string') {
2550
2807
  return new TypeError('Expected "string" but received "' + typeof obj_promptTemplateDevName + '" (at "' + path_promptTemplateDevName + '")');
2551
2808
  }
2809
+ const obj_rawPrompt = obj.rawPrompt;
2810
+ const path_rawPrompt = path + '.rawPrompt';
2811
+ let obj_rawPrompt_union0 = null;
2812
+ const obj_rawPrompt_union0_error = (() => {
2813
+ if (typeof obj_rawPrompt !== 'string') {
2814
+ return new TypeError('Expected "string" but received "' + typeof obj_rawPrompt + '" (at "' + path_rawPrompt + '")');
2815
+ }
2816
+ })();
2817
+ if (obj_rawPrompt_union0_error != null) {
2818
+ obj_rawPrompt_union0 = obj_rawPrompt_union0_error.message;
2819
+ }
2820
+ let obj_rawPrompt_union1 = null;
2821
+ const obj_rawPrompt_union1_error = (() => {
2822
+ if (obj_rawPrompt !== null) {
2823
+ return new TypeError('Expected "null" but received "' + typeof obj_rawPrompt + '" (at "' + path_rawPrompt + '")');
2824
+ }
2825
+ })();
2826
+ if (obj_rawPrompt_union1_error != null) {
2827
+ obj_rawPrompt_union1 = obj_rawPrompt_union1_error.message;
2828
+ }
2829
+ if (obj_rawPrompt_union0 && obj_rawPrompt_union1) {
2830
+ let message = 'Object doesn\'t match union (at "' + path_rawPrompt + '")';
2831
+ message += '\n' + obj_rawPrompt_union0.split('\n').map((line) => '\t' + line).join('\n');
2832
+ message += '\n' + obj_rawPrompt_union1.split('\n').map((line) => '\t' + line).join('\n');
2833
+ return new TypeError(message);
2834
+ }
2552
2835
  const obj_requestId = obj.requestId;
2553
2836
  const path_requestId = path + '.requestId';
2554
2837
  if (typeof obj_requestId !== 'string') {
@@ -2563,7 +2846,7 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2563
2846
  for (let i = 0; i < obj_requestMessages.length; i++) {
2564
2847
  const obj_requestMessages_item = obj_requestMessages[i];
2565
2848
  const path_requestMessages_item = path_requestMessages + '[' + i + ']';
2566
- const referencepath_requestMessages_itemValidationError = validate$9(obj_requestMessages_item, path_requestMessages_item);
2849
+ const referencepath_requestMessages_itemValidationError = validate$f(obj_requestMessages_item, path_requestMessages_item);
2567
2850
  if (referencepath_requestMessages_itemValidationError !== null) {
2568
2851
  let message = 'Object doesn\'t match EinsteinPromptTemplateMaskContentRepresentation (at "' + path_requestMessages_item + '")\n';
2569
2852
  message += referencepath_requestMessages_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2580,7 +2863,7 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2580
2863
  for (let i = 0; i < obj_responseMessages.length; i++) {
2581
2864
  const obj_responseMessages_item = obj_responseMessages[i];
2582
2865
  const path_responseMessages_item = path_responseMessages + '[' + i + ']';
2583
- const referencepath_responseMessages_itemValidationError = validate$9(obj_responseMessages_item, path_responseMessages_item);
2866
+ const referencepath_responseMessages_itemValidationError = validate$f(obj_responseMessages_item, path_responseMessages_item);
2584
2867
  if (referencepath_responseMessages_itemValidationError !== null) {
2585
2868
  let message = 'Object doesn\'t match EinsteinPromptTemplateMaskContentRepresentation (at "' + path_responseMessages_item + '")\n';
2586
2869
  message += referencepath_responseMessages_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2597,7 +2880,7 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2597
2880
  for (let i = 0; i < obj_slotsMaskingInformation.length; i++) {
2598
2881
  const obj_slotsMaskingInformation_item = obj_slotsMaskingInformation[i];
2599
2882
  const path_slotsMaskingInformation_item = path_slotsMaskingInformation + '[' + i + ']';
2600
- const referencepath_slotsMaskingInformation_itemValidationError = validate$8(obj_slotsMaskingInformation_item, path_slotsMaskingInformation_item);
2883
+ const referencepath_slotsMaskingInformation_itemValidationError = validate$e(obj_slotsMaskingInformation_item, path_slotsMaskingInformation_item);
2601
2884
  if (referencepath_slotsMaskingInformation_itemValidationError !== null) {
2602
2885
  let message = 'Object doesn\'t match EinsteinPromptTemplateMaskDataRepresentation (at "' + path_slotsMaskingInformation_item + '")\n';
2603
2886
  message += referencepath_slotsMaskingInformation_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -2608,31 +2891,38 @@ function validate$7(obj, path = 'EinsteinPromptTemplateGenerationsRepresentation
2608
2891
  })();
2609
2892
  return v_error === undefined ? null : v_error;
2610
2893
  }
2611
- const RepresentationType$4 = 'EinsteinPromptTemplateGenerationsRepresentation';
2612
- function keyBuilder$7(luvio, config) {
2613
- return keyPrefix + '::' + RepresentationType$4 + ':' + config.requestId;
2894
+ const RepresentationType$7 = 'EinsteinPromptTemplateGenerationsRepresentation';
2895
+ function keyBuilder$j(luvio, config) {
2896
+ return keyPrefix + '::' + RepresentationType$7 + ':' + config.requestId;
2614
2897
  }
2615
2898
  function keyBuilderFromType$1(luvio, object) {
2616
2899
  const keyParams = {
2617
2900
  requestId: object.requestId
2618
2901
  };
2619
- return keyBuilder$7(luvio, keyParams);
2902
+ return keyBuilder$j(luvio, keyParams);
2620
2903
  }
2621
- function normalize$4(input, existing, path, luvio, store, timestamp) {
2904
+ function normalize$7(input, existing, path, luvio, store, timestamp) {
2622
2905
  return input;
2623
2906
  }
2624
- const select$d = function EinsteinPromptTemplateGenerationsRepresentationSelect() {
2625
- const { selections: EinsteinPromptTemplateAttachmentRepresentation__selections, opaque: EinsteinPromptTemplateAttachmentRepresentation__opaque, } = select$i();
2626
- const { selections: EinsteinPromptTemplateGenerationsErrorRepresentation__selections, opaque: EinsteinPromptTemplateGenerationsErrorRepresentation__opaque, } = select$h();
2627
- const { selections: EinsteinLlmGenerationItemRepresentation__selections, opaque: EinsteinLlmGenerationItemRepresentation__opaque, } = select$n();
2628
- const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$m();
2629
- const { selections: EinsteinPromptTemplateMaskContentRepresentation__selections, opaque: EinsteinPromptTemplateMaskContentRepresentation__opaque, } = select$f();
2630
- const { selections: EinsteinPromptTemplateMaskDataRepresentation__selections, opaque: EinsteinPromptTemplateMaskDataRepresentation__opaque, } = select$e();
2907
+ const select$n = function EinsteinPromptTemplateGenerationsRepresentationSelect() {
2908
+ const { selections: EinsteinLlmGenerationCitationRepresentation__selections, opaque: EinsteinLlmGenerationCitationRepresentation__opaque, } = select$u();
2909
+ const { selections: EinsteinPromptTemplateAttachmentRepresentation__selections, opaque: EinsteinPromptTemplateAttachmentRepresentation__opaque, } = select$s();
2910
+ const { selections: EinsteinPromptTemplateGenerationsErrorRepresentation__selections, opaque: EinsteinPromptTemplateGenerationsErrorRepresentation__opaque, } = select$r();
2911
+ const { selections: EinsteinLlmGenerationItemRepresentation__selections, opaque: EinsteinLlmGenerationItemRepresentation__opaque, } = select$z();
2912
+ const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$y();
2913
+ const { selections: EinsteinPromptTemplateMaskContentRepresentation__selections, opaque: EinsteinPromptTemplateMaskContentRepresentation__opaque, } = select$p();
2914
+ const { selections: EinsteinPromptTemplateMaskDataRepresentation__selections, opaque: EinsteinPromptTemplateMaskDataRepresentation__opaque, } = select$o();
2631
2915
  return {
2632
2916
  kind: 'Fragment',
2633
- version: VERSION$6,
2917
+ version: VERSION$9,
2634
2918
  private: [],
2635
2919
  selections: [
2920
+ {
2921
+ name: 'citations',
2922
+ kind: 'Object',
2923
+ selections: EinsteinLlmGenerationCitationRepresentation__selections,
2924
+ required: false
2925
+ },
2636
2926
  {
2637
2927
  name: 'fileData',
2638
2928
  kind: 'Object',
@@ -2672,6 +2962,10 @@ const select$d = function EinsteinPromptTemplateGenerationsRepresentationSelect(
2672
2962
  name: 'promptTemplateDevName',
2673
2963
  kind: 'Scalar'
2674
2964
  },
2965
+ {
2966
+ name: 'rawPrompt',
2967
+ kind: 'Scalar'
2968
+ },
2675
2969
  {
2676
2970
  name: 'requestId',
2677
2971
  kind: 'Scalar'
@@ -2700,7 +2994,7 @@ const select$d = function EinsteinPromptTemplateGenerationsRepresentationSelect(
2700
2994
  ]
2701
2995
  };
2702
2996
  };
2703
- function equals$6(existing, incoming) {
2997
+ function equals$9(existing, incoming) {
2704
2998
  const existing_promptTemplateDevName = existing.promptTemplateDevName;
2705
2999
  const incoming_promptTemplateDevName = incoming.promptTemplateDevName;
2706
3000
  if (!(existing_promptTemplateDevName === incoming_promptTemplateDevName)) {
@@ -2711,6 +3005,19 @@ function equals$6(existing, incoming) {
2711
3005
  if (!(existing_requestId === incoming_requestId)) {
2712
3006
  return false;
2713
3007
  }
3008
+ const existing_citations = existing.citations;
3009
+ const incoming_citations = incoming.citations;
3010
+ // if at least one of these optionals is defined
3011
+ if (existing_citations !== undefined || incoming_citations !== undefined) {
3012
+ // if one of these is not defined we know the other is defined and therefore
3013
+ // not equal
3014
+ if (existing_citations === undefined || incoming_citations === undefined) {
3015
+ return false;
3016
+ }
3017
+ if (!(equals$g(existing_citations, incoming_citations))) {
3018
+ return false;
3019
+ }
3020
+ }
2714
3021
  const existing_fileData = existing.fileData;
2715
3022
  const incoming_fileData = incoming.fileData;
2716
3023
  // if at least one of these optionals is defined
@@ -2721,7 +3028,7 @@ function equals$6(existing, incoming) {
2721
3028
  return false;
2722
3029
  }
2723
3030
  const equals_fileData_items = equalsArray(existing_fileData, incoming_fileData, (existing_fileData_item, incoming_fileData_item) => {
2724
- if (!(equals$b(existing_fileData_item, incoming_fileData_item))) {
3031
+ if (!(equals$e(existing_fileData_item, incoming_fileData_item))) {
2725
3032
  return false;
2726
3033
  }
2727
3034
  });
@@ -2739,7 +3046,7 @@ function equals$6(existing, incoming) {
2739
3046
  return false;
2740
3047
  }
2741
3048
  const equals_generationErrors_items = equalsArray(existing_generationErrors, incoming_generationErrors, (existing_generationErrors_item, incoming_generationErrors_item) => {
2742
- if (!(equals$a(existing_generationErrors_item, incoming_generationErrors_item))) {
3049
+ if (!(equals$d(existing_generationErrors_item, incoming_generationErrors_item))) {
2743
3050
  return false;
2744
3051
  }
2745
3052
  });
@@ -2750,7 +3057,7 @@ function equals$6(existing, incoming) {
2750
3057
  const existing_generations = existing.generations;
2751
3058
  const incoming_generations = incoming.generations;
2752
3059
  const equals_generations_items = equalsArray(existing_generations, incoming_generations, (existing_generations_item, incoming_generations_item) => {
2753
- if (!(equals$f(existing_generations_item, incoming_generations_item))) {
3060
+ if (!(equals$k(existing_generations_item, incoming_generations_item))) {
2754
3061
  return false;
2755
3062
  }
2756
3063
  });
@@ -2780,7 +3087,7 @@ function equals$6(existing, incoming) {
2780
3087
  if (!(existing_parameters === incoming_parameters
2781
3088
  || (existing_parameters != null &&
2782
3089
  incoming_parameters != null &&
2783
- equals$e(existing_parameters, incoming_parameters)))) {
3090
+ equals$j(existing_parameters, incoming_parameters)))) {
2784
3091
  return false;
2785
3092
  }
2786
3093
  const existing_prompt = existing.prompt;
@@ -2788,6 +3095,11 @@ function equals$6(existing, incoming) {
2788
3095
  if (!(existing_prompt === incoming_prompt)) {
2789
3096
  return false;
2790
3097
  }
3098
+ const existing_rawPrompt = existing.rawPrompt;
3099
+ const incoming_rawPrompt = incoming.rawPrompt;
3100
+ if (!(existing_rawPrompt === incoming_rawPrompt)) {
3101
+ return false;
3102
+ }
2791
3103
  const existing_requestMessages = existing.requestMessages;
2792
3104
  const incoming_requestMessages = incoming.requestMessages;
2793
3105
  // if at least one of these optionals is defined
@@ -2798,7 +3110,7 @@ function equals$6(existing, incoming) {
2798
3110
  return false;
2799
3111
  }
2800
3112
  const equals_requestMessages_items = equalsArray(existing_requestMessages, incoming_requestMessages, (existing_requestMessages_item, incoming_requestMessages_item) => {
2801
- if (!(equals$8(existing_requestMessages_item, incoming_requestMessages_item))) {
3113
+ if (!(equals$b(existing_requestMessages_item, incoming_requestMessages_item))) {
2802
3114
  return false;
2803
3115
  }
2804
3116
  });
@@ -2816,7 +3128,7 @@ function equals$6(existing, incoming) {
2816
3128
  return false;
2817
3129
  }
2818
3130
  const equals_responseMessages_items = equalsArray(existing_responseMessages, incoming_responseMessages, (existing_responseMessages_item, incoming_responseMessages_item) => {
2819
- if (!(equals$8(existing_responseMessages_item, incoming_responseMessages_item))) {
3131
+ if (!(equals$b(existing_responseMessages_item, incoming_responseMessages_item))) {
2820
3132
  return false;
2821
3133
  }
2822
3134
  });
@@ -2834,7 +3146,7 @@ function equals$6(existing, incoming) {
2834
3146
  return false;
2835
3147
  }
2836
3148
  const equals_slotsMaskingInformation_items = equalsArray(existing_slotsMaskingInformation, incoming_slotsMaskingInformation, (existing_slotsMaskingInformation_item, incoming_slotsMaskingInformation_item) => {
2837
- if (!(equals$7(existing_slotsMaskingInformation_item, incoming_slotsMaskingInformation_item))) {
3149
+ if (!(equals$a(existing_slotsMaskingInformation_item, incoming_slotsMaskingInformation_item))) {
2838
3150
  return false;
2839
3151
  }
2840
3152
  });
@@ -2844,41 +3156,41 @@ function equals$6(existing, incoming) {
2844
3156
  }
2845
3157
  return true;
2846
3158
  }
2847
- const ingest$4 = function EinsteinPromptTemplateGenerationsRepresentationIngest(input, path, luvio, store, timestamp) {
3159
+ const ingest$7 = function EinsteinPromptTemplateGenerationsRepresentationIngest(input, path, luvio, store, timestamp) {
2848
3160
  if (process.env.NODE_ENV !== 'production') {
2849
- const validateError = validate$7(input);
3161
+ const validateError = validate$d(input);
2850
3162
  if (validateError !== null) {
2851
3163
  throw validateError;
2852
3164
  }
2853
3165
  }
2854
3166
  const key = keyBuilderFromType$1(luvio, input);
2855
- const ttlToUse = TTL$4;
2856
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$4, "EinsteinLLM", VERSION$6, RepresentationType$4, equals$6);
3167
+ const ttlToUse = TTL$7;
3168
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$7, "EinsteinLLM", VERSION$9, RepresentationType$7, equals$9);
2857
3169
  return createLink(key);
2858
3170
  };
2859
- function getTypeCacheKeys$4(rootKeySet, luvio, input, fullPathFactory) {
3171
+ function getTypeCacheKeys$7(rootKeySet, luvio, input, fullPathFactory) {
2860
3172
  // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
2861
3173
  const rootKey = keyBuilderFromType$1(luvio, input);
2862
3174
  rootKeySet.set(rootKey, {
2863
3175
  namespace: keyPrefix,
2864
- representationName: RepresentationType$4,
3176
+ representationName: RepresentationType$7,
2865
3177
  mergeable: false
2866
3178
  });
2867
3179
  }
2868
3180
 
2869
- function select$c(luvio, params) {
2870
- return select$d();
3181
+ function select$m(luvio, params) {
3182
+ return select$n();
2871
3183
  }
2872
- function getResponseCacheKeys$6(storeKeyMap, luvio, resourceParams, response) {
2873
- getTypeCacheKeys$4(storeKeyMap, luvio, response);
3184
+ function getResponseCacheKeys$d(storeKeyMap, luvio, resourceParams, response) {
3185
+ getTypeCacheKeys$7(storeKeyMap, luvio, response);
2874
3186
  }
2875
- function ingestSuccess$6(luvio, resourceParams, response) {
3187
+ function ingestSuccess$d(luvio, resourceParams, response) {
2876
3188
  const { body } = response;
2877
3189
  const key = keyBuilderFromType$1(luvio, body);
2878
- luvio.storeIngest(key, ingest$4, body);
3190
+ luvio.storeIngest(key, ingest$7, body);
2879
3191
  const snapshot = luvio.storeLookup({
2880
3192
  recordId: key,
2881
- node: select$c(),
3193
+ node: select$m(),
2882
3194
  variables: {},
2883
3195
  });
2884
3196
  if (process.env.NODE_ENV !== 'production') {
@@ -2889,7 +3201,7 @@ function ingestSuccess$6(luvio, resourceParams, response) {
2889
3201
  deepFreeze(snapshot.data);
2890
3202
  return snapshot;
2891
3203
  }
2892
- function createResourceRequest$6(config) {
3204
+ function createResourceRequest$d(config) {
2893
3205
  const headers = {};
2894
3206
  return {
2895
3207
  baseUri: '/services/data/v65.0',
@@ -2903,48 +3215,48 @@ function createResourceRequest$6(config) {
2903
3215
  };
2904
3216
  }
2905
3217
 
2906
- const adapterName$6 = 'createGenerationsForPromptTemplate';
3218
+ const adapterName$d = 'createGenerationsForPromptTemplate';
2907
3219
  const createGenerationsForPromptTemplate_ConfigPropertyMetadata = [
2908
3220
  generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
2909
3221
  generateParamConfigMetadata('versionId', false, 1 /* QueryParameter */, 0 /* String */),
2910
3222
  generateParamConfigMetadata('promptTemplateGenerationsInput', true, 2 /* Body */, 4 /* Unsupported */),
2911
3223
  ];
2912
- const createGenerationsForPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$6, createGenerationsForPromptTemplate_ConfigPropertyMetadata);
2913
- const createResourceParams$6 = /*#__PURE__*/ createResourceParams$a(createGenerationsForPromptTemplate_ConfigPropertyMetadata);
2914
- function typeCheckConfig$6(untrustedConfig) {
3224
+ const createGenerationsForPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$d, createGenerationsForPromptTemplate_ConfigPropertyMetadata);
3225
+ const createResourceParams$d = /*#__PURE__*/ createResourceParams$h(createGenerationsForPromptTemplate_ConfigPropertyMetadata);
3226
+ function typeCheckConfig$d(untrustedConfig) {
2915
3227
  const config = {};
2916
- typeCheckConfig$a(untrustedConfig, config, createGenerationsForPromptTemplate_ConfigPropertyMetadata);
3228
+ typeCheckConfig$h(untrustedConfig, config, createGenerationsForPromptTemplate_ConfigPropertyMetadata);
2917
3229
  const untrustedConfig_promptTemplateGenerationsInput = untrustedConfig.promptTemplateGenerationsInput;
2918
- const referenceEinsteinPromptTemplateGenerationsInputRepresentationValidationError = validate$e(untrustedConfig_promptTemplateGenerationsInput);
3230
+ const referenceEinsteinPromptTemplateGenerationsInputRepresentationValidationError = validate$m(untrustedConfig_promptTemplateGenerationsInput);
2919
3231
  if (referenceEinsteinPromptTemplateGenerationsInputRepresentationValidationError === null) {
2920
3232
  config.promptTemplateGenerationsInput = untrustedConfig_promptTemplateGenerationsInput;
2921
3233
  }
2922
3234
  return config;
2923
3235
  }
2924
- function validateAdapterConfig$6(untrustedConfig, configPropertyNames) {
3236
+ function validateAdapterConfig$d(untrustedConfig, configPropertyNames) {
2925
3237
  if (!untrustedIsObject(untrustedConfig)) {
2926
3238
  return null;
2927
3239
  }
2928
3240
  if (process.env.NODE_ENV !== 'production') {
2929
3241
  validateConfig(untrustedConfig, configPropertyNames);
2930
3242
  }
2931
- const config = typeCheckConfig$6(untrustedConfig);
3243
+ const config = typeCheckConfig$d(untrustedConfig);
2932
3244
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
2933
3245
  return null;
2934
3246
  }
2935
3247
  return config;
2936
3248
  }
2937
- function buildNetworkSnapshot$6(luvio, config, options) {
2938
- const resourceParams = createResourceParams$6(config);
2939
- const request = createResourceRequest$6(resourceParams);
3249
+ function buildNetworkSnapshot$d(luvio, config, options) {
3250
+ const resourceParams = createResourceParams$d(config);
3251
+ const request = createResourceRequest$d(resourceParams);
2940
3252
  return luvio.dispatchResourceRequest(request, options)
2941
3253
  .then((response) => {
2942
3254
  return luvio.handleSuccessResponse(() => {
2943
- const snapshot = ingestSuccess$6(luvio, resourceParams, response);
3255
+ const snapshot = ingestSuccess$d(luvio, resourceParams, response);
2944
3256
  return luvio.storeBroadcast().then(() => snapshot);
2945
3257
  }, () => {
2946
3258
  const cache = new StoreKeyMap();
2947
- getResponseCacheKeys$6(cache, luvio, resourceParams, response.body);
3259
+ getResponseCacheKeys$d(cache, luvio, resourceParams, response.body);
2948
3260
  return cache;
2949
3261
  });
2950
3262
  }, (response) => {
@@ -2954,18 +3266,18 @@ function buildNetworkSnapshot$6(luvio, config, options) {
2954
3266
  }
2955
3267
  const createGenerationsForPromptTemplateAdapterFactory = (luvio) => {
2956
3268
  return function createGenerationsForPromptTemplate(untrustedConfig) {
2957
- const config = validateAdapterConfig$6(untrustedConfig, createGenerationsForPromptTemplate_ConfigPropertyNames);
3269
+ const config = validateAdapterConfig$d(untrustedConfig, createGenerationsForPromptTemplate_ConfigPropertyNames);
2958
3270
  // Invalid or incomplete config
2959
3271
  if (config === null) {
2960
3272
  throw new Error('Invalid config for "createGenerationsForPromptTemplate"');
2961
3273
  }
2962
- return buildNetworkSnapshot$6(luvio, config);
3274
+ return buildNetworkSnapshot$d(luvio, config);
2963
3275
  };
2964
3276
  };
2965
3277
 
2966
- const TTL$3 = 100;
2967
- const VERSION$5 = "a90a51578e2fdd7a9741d310bed22b1d";
2968
- function validate$6(obj, path = 'EinsteinPromptTemplateRepresentation') {
3278
+ const TTL$6 = 100;
3279
+ const VERSION$8 = "a90a51578e2fdd7a9741d310bed22b1d";
3280
+ function validate$c(obj, path = 'EinsteinPromptTemplateRepresentation') {
2969
3281
  const v_error = (() => {
2970
3282
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2971
3283
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -2973,7 +3285,7 @@ function validate$6(obj, path = 'EinsteinPromptTemplateRepresentation') {
2973
3285
  if (obj.additionalData !== undefined) {
2974
3286
  const obj_additionalData = obj.additionalData;
2975
3287
  const path_additionalData = path + '.additionalData';
2976
- const referencepath_additionalDataValidationError = validate$h(obj_additionalData, path_additionalData);
3288
+ const referencepath_additionalDataValidationError = validate$p(obj_additionalData, path_additionalData);
2977
3289
  if (referencepath_additionalDataValidationError !== null) {
2978
3290
  let message = 'Object doesn\'t match WrappedMap (at "' + path_additionalData + '")\n';
2979
3291
  message += referencepath_additionalDataValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -3041,24 +3353,24 @@ function validate$6(obj, path = 'EinsteinPromptTemplateRepresentation') {
3041
3353
  })();
3042
3354
  return v_error === undefined ? null : v_error;
3043
3355
  }
3044
- const RepresentationType$3 = 'EinsteinPromptTemplateRepresentation';
3045
- function keyBuilder$6(luvio, config) {
3046
- return keyPrefix + '::' + RepresentationType$3 + ':' + config.versionId;
3356
+ const RepresentationType$6 = 'EinsteinPromptTemplateRepresentation';
3357
+ function keyBuilder$i(luvio, config) {
3358
+ return keyPrefix + '::' + RepresentationType$6 + ':' + config.versionId;
3047
3359
  }
3048
3360
  function keyBuilderFromType(luvio, object) {
3049
3361
  const keyParams = {
3050
3362
  versionId: object.versionId
3051
3363
  };
3052
- return keyBuilder$6(luvio, keyParams);
3364
+ return keyBuilder$i(luvio, keyParams);
3053
3365
  }
3054
- function normalize$3(input, existing, path, luvio, store, timestamp) {
3366
+ function normalize$6(input, existing, path, luvio, store, timestamp) {
3055
3367
  return input;
3056
3368
  }
3057
- const select$b = function EinsteinPromptTemplateRepresentationSelect() {
3058
- const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$m();
3369
+ const select$l = function EinsteinPromptTemplateRepresentationSelect() {
3370
+ const { selections: WrappedMap__selections, opaque: WrappedMap__opaque, } = select$y();
3059
3371
  return {
3060
3372
  kind: 'Fragment',
3061
- version: VERSION$5,
3373
+ version: VERSION$8,
3062
3374
  private: [],
3063
3375
  selections: [
3064
3376
  {
@@ -3106,7 +3418,7 @@ const select$b = function EinsteinPromptTemplateRepresentationSelect() {
3106
3418
  ]
3107
3419
  };
3108
3420
  };
3109
- function equals$5(existing, incoming) {
3421
+ function equals$8(existing, incoming) {
3110
3422
  const existing_hasWarning = existing.hasWarning;
3111
3423
  const incoming_hasWarning = incoming.hasWarning;
3112
3424
  if (!(existing_hasWarning === incoming_hasWarning)) {
@@ -3162,7 +3474,7 @@ function equals$5(existing, incoming) {
3162
3474
  if (existing_additionalData === undefined || incoming_additionalData === undefined) {
3163
3475
  return false;
3164
3476
  }
3165
- if (!(equals$e(existing_additionalData, incoming_additionalData))) {
3477
+ if (!(equals$j(existing_additionalData, incoming_additionalData))) {
3166
3478
  return false;
3167
3479
  }
3168
3480
  }
@@ -3188,41 +3500,41 @@ function equals$5(existing, incoming) {
3188
3500
  }
3189
3501
  return true;
3190
3502
  }
3191
- const ingest$3 = function EinsteinPromptTemplateRepresentationIngest(input, path, luvio, store, timestamp) {
3503
+ const ingest$6 = function EinsteinPromptTemplateRepresentationIngest(input, path, luvio, store, timestamp) {
3192
3504
  if (process.env.NODE_ENV !== 'production') {
3193
- const validateError = validate$6(input);
3505
+ const validateError = validate$c(input);
3194
3506
  if (validateError !== null) {
3195
3507
  throw validateError;
3196
3508
  }
3197
3509
  }
3198
3510
  const key = keyBuilderFromType(luvio, input);
3199
- const ttlToUse = TTL$3;
3200
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$3, "EinsteinLLM", VERSION$5, RepresentationType$3, equals$5);
3511
+ const ttlToUse = TTL$6;
3512
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$6, "EinsteinLLM", VERSION$8, RepresentationType$6, equals$8);
3201
3513
  return createLink(key);
3202
3514
  };
3203
- function getTypeCacheKeys$3(rootKeySet, luvio, input, fullPathFactory) {
3515
+ function getTypeCacheKeys$6(rootKeySet, luvio, input, fullPathFactory) {
3204
3516
  // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
3205
3517
  const rootKey = keyBuilderFromType(luvio, input);
3206
3518
  rootKeySet.set(rootKey, {
3207
3519
  namespace: keyPrefix,
3208
- representationName: RepresentationType$3,
3520
+ representationName: RepresentationType$6,
3209
3521
  mergeable: false
3210
3522
  });
3211
3523
  }
3212
3524
 
3213
- function select$a(luvio, params) {
3214
- return select$b();
3525
+ function select$k(luvio, params) {
3526
+ return select$l();
3215
3527
  }
3216
- function getResponseCacheKeys$5(storeKeyMap, luvio, resourceParams, response) {
3217
- getTypeCacheKeys$3(storeKeyMap, luvio, response);
3528
+ function getResponseCacheKeys$c(storeKeyMap, luvio, resourceParams, response) {
3529
+ getTypeCacheKeys$6(storeKeyMap, luvio, response);
3218
3530
  }
3219
- function ingestSuccess$5(luvio, resourceParams, response) {
3531
+ function ingestSuccess$c(luvio, resourceParams, response) {
3220
3532
  const { body } = response;
3221
3533
  const key = keyBuilderFromType(luvio, body);
3222
- luvio.storeIngest(key, ingest$3, body);
3534
+ luvio.storeIngest(key, ingest$6, body);
3223
3535
  const snapshot = luvio.storeLookup({
3224
3536
  recordId: key,
3225
- node: select$a(),
3537
+ node: select$k(),
3226
3538
  variables: {},
3227
3539
  });
3228
3540
  if (process.env.NODE_ENV !== 'production') {
@@ -3233,7 +3545,7 @@ function ingestSuccess$5(luvio, resourceParams, response) {
3233
3545
  deepFreeze(snapshot.data);
3234
3546
  return snapshot;
3235
3547
  }
3236
- function createResourceRequest$5(config) {
3548
+ function createResourceRequest$c(config) {
3237
3549
  const headers = {};
3238
3550
  return {
3239
3551
  baseUri: '/services/data/v65.0',
@@ -3247,19 +3559,18 @@ function createResourceRequest$5(config) {
3247
3559
  };
3248
3560
  }
3249
3561
 
3250
- const adapterName$5 = 'createPromptTemplate';
3562
+ const adapterName$c = 'createPromptTemplate';
3251
3563
  const createPromptTemplate_ConfigPropertyMetadata = [
3252
3564
  generateParamConfigMetadata('apiName', true, 2 /* Body */, 0 /* String */),
3253
3565
  generateParamConfigMetadata('childRelationships', true, 2 /* Body */, 4 /* Unsupported */),
3254
- generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */, true),
3566
+ generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */),
3255
3567
  generateParamConfigMetadata('id', false, 2 /* Body */, 0 /* String */),
3256
- generateParamConfigMetadata('isStandard', true, 2 /* Body */, 1 /* Boolean */),
3257
3568
  ];
3258
- const createPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$5, createPromptTemplate_ConfigPropertyMetadata);
3259
- const createResourceParams$5 = /*#__PURE__*/ createResourceParams$a(createPromptTemplate_ConfigPropertyMetadata);
3260
- function typeCheckConfig$5(untrustedConfig) {
3569
+ const createPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$c, createPromptTemplate_ConfigPropertyMetadata);
3570
+ const createResourceParams$c = /*#__PURE__*/ createResourceParams$h(createPromptTemplate_ConfigPropertyMetadata);
3571
+ function typeCheckConfig$c(untrustedConfig) {
3261
3572
  const config = {};
3262
- typeCheckConfig$a(untrustedConfig, config, createPromptTemplate_ConfigPropertyMetadata);
3573
+ typeCheckConfig$h(untrustedConfig, config, createPromptTemplate_ConfigPropertyMetadata);
3263
3574
  const untrustedConfig_childRelationships = untrustedConfig.childRelationships;
3264
3575
  if (untrustedIsObject(untrustedConfig_childRelationships)) {
3265
3576
  const untrustedConfig_childRelationships_object = {};
@@ -3276,53 +3587,46 @@ function typeCheckConfig$5(untrustedConfig) {
3276
3587
  }
3277
3588
  }
3278
3589
  const untrustedConfig_fields = untrustedConfig.fields;
3279
- if (ArrayIsArray$1(untrustedConfig_fields)) {
3280
- const untrustedConfig_fields_array = [];
3281
- for (let i = 0, arrayLength = untrustedConfig_fields.length; i < arrayLength; i++) {
3282
- const untrustedConfig_fields_item = untrustedConfig_fields[i];
3283
- if (untrustedIsObject(untrustedConfig_fields_item)) {
3284
- const untrustedConfig_fields_item_object = {};
3285
- const untrustedConfig_fields_item_keys = Object.keys(untrustedConfig_fields_item);
3286
- for (let i = 0, arrayLength = untrustedConfig_fields_item_keys.length; i < arrayLength; i++) {
3287
- const key = untrustedConfig_fields_item_keys[i];
3288
- const untrustedConfig_fields_item_prop = untrustedConfig_fields_item[key];
3289
- if (untrustedConfig_fields_item_object !== undefined) {
3290
- untrustedConfig_fields_item_object[key] = untrustedConfig_fields_item_prop;
3291
- }
3292
- }
3293
- if (untrustedConfig_fields_item_object !== undefined && Object.keys(untrustedConfig_fields_item_object).length >= 0) {
3294
- untrustedConfig_fields_array.push(untrustedConfig_fields_item_object);
3295
- }
3590
+ if (untrustedIsObject(untrustedConfig_fields)) {
3591
+ const untrustedConfig_fields_object = {};
3592
+ const untrustedConfig_fields_keys = Object.keys(untrustedConfig_fields);
3593
+ for (let i = 0, arrayLength = untrustedConfig_fields_keys.length; i < arrayLength; i++) {
3594
+ const key = untrustedConfig_fields_keys[i];
3595
+ const untrustedConfig_fields_prop = untrustedConfig_fields[key];
3596
+ if (untrustedConfig_fields_object !== undefined) {
3597
+ untrustedConfig_fields_object[key] = untrustedConfig_fields_prop;
3296
3598
  }
3297
3599
  }
3298
- config.fields = untrustedConfig_fields_array;
3600
+ if (untrustedConfig_fields_object !== undefined && Object.keys(untrustedConfig_fields_object).length >= 0) {
3601
+ config.fields = untrustedConfig_fields_object;
3602
+ }
3299
3603
  }
3300
3604
  return config;
3301
3605
  }
3302
- function validateAdapterConfig$5(untrustedConfig, configPropertyNames) {
3606
+ function validateAdapterConfig$c(untrustedConfig, configPropertyNames) {
3303
3607
  if (!untrustedIsObject(untrustedConfig)) {
3304
3608
  return null;
3305
3609
  }
3306
3610
  if (process.env.NODE_ENV !== 'production') {
3307
3611
  validateConfig(untrustedConfig, configPropertyNames);
3308
3612
  }
3309
- const config = typeCheckConfig$5(untrustedConfig);
3613
+ const config = typeCheckConfig$c(untrustedConfig);
3310
3614
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
3311
3615
  return null;
3312
3616
  }
3313
3617
  return config;
3314
3618
  }
3315
- function buildNetworkSnapshot$5(luvio, config, options) {
3316
- const resourceParams = createResourceParams$5(config);
3317
- const request = createResourceRequest$5(resourceParams);
3619
+ function buildNetworkSnapshot$c(luvio, config, options) {
3620
+ const resourceParams = createResourceParams$c(config);
3621
+ const request = createResourceRequest$c(resourceParams);
3318
3622
  return luvio.dispatchResourceRequest(request, options)
3319
3623
  .then((response) => {
3320
3624
  return luvio.handleSuccessResponse(() => {
3321
- const snapshot = ingestSuccess$5(luvio, resourceParams, response);
3625
+ const snapshot = ingestSuccess$c(luvio, resourceParams, response);
3322
3626
  return luvio.storeBroadcast().then(() => snapshot);
3323
3627
  }, () => {
3324
3628
  const cache = new StoreKeyMap();
3325
- getResponseCacheKeys$5(cache, luvio, resourceParams, response.body);
3629
+ getResponseCacheKeys$c(cache, luvio, resourceParams, response.body);
3326
3630
  return cache;
3327
3631
  });
3328
3632
  }, (response) => {
@@ -3332,28 +3636,28 @@ function buildNetworkSnapshot$5(luvio, config, options) {
3332
3636
  }
3333
3637
  const createPromptTemplateAdapterFactory = (luvio) => {
3334
3638
  return function createPromptTemplate(untrustedConfig) {
3335
- const config = validateAdapterConfig$5(untrustedConfig, createPromptTemplate_ConfigPropertyNames);
3639
+ const config = validateAdapterConfig$c(untrustedConfig, createPromptTemplate_ConfigPropertyNames);
3336
3640
  // Invalid or incomplete config
3337
3641
  if (config === null) {
3338
3642
  throw new Error('Invalid config for "createPromptTemplate"');
3339
3643
  }
3340
- return buildNetworkSnapshot$5(luvio, config);
3644
+ return buildNetworkSnapshot$c(luvio, config);
3341
3645
  };
3342
3646
  };
3343
3647
 
3344
- function select$9(luvio, params) {
3345
- return select$b();
3648
+ function select$j(luvio, params) {
3649
+ return select$l();
3346
3650
  }
3347
- function getResponseCacheKeys$4(storeKeyMap, luvio, resourceParams, response) {
3348
- getTypeCacheKeys$3(storeKeyMap, luvio, response);
3651
+ function getResponseCacheKeys$b(storeKeyMap, luvio, resourceParams, response) {
3652
+ getTypeCacheKeys$6(storeKeyMap, luvio, response);
3349
3653
  }
3350
- function ingestSuccess$4(luvio, resourceParams, response) {
3654
+ function ingestSuccess$b(luvio, resourceParams, response) {
3351
3655
  const { body } = response;
3352
3656
  const key = keyBuilderFromType(luvio, body);
3353
- luvio.storeIngest(key, ingest$3, body);
3657
+ luvio.storeIngest(key, ingest$6, body);
3354
3658
  const snapshot = luvio.storeLookup({
3355
3659
  recordId: key,
3356
- node: select$9(),
3660
+ node: select$j(),
3357
3661
  variables: {},
3358
3662
  });
3359
3663
  if (process.env.NODE_ENV !== 'production') {
@@ -3364,7 +3668,7 @@ function ingestSuccess$4(luvio, resourceParams, response) {
3364
3668
  deepFreeze(snapshot.data);
3365
3669
  return snapshot;
3366
3670
  }
3367
- function createResourceRequest$4(config) {
3671
+ function createResourceRequest$b(config) {
3368
3672
  const headers = {};
3369
3673
  return {
3370
3674
  baseUri: '/services/data/v65.0',
@@ -3378,20 +3682,19 @@ function createResourceRequest$4(config) {
3378
3682
  };
3379
3683
  }
3380
3684
 
3381
- const adapterName$4 = 'createPromptTemplateVersion';
3685
+ const adapterName$b = 'createPromptTemplateVersion';
3382
3686
  const createPromptTemplateVersion_ConfigPropertyMetadata = [
3383
3687
  generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
3384
3688
  generateParamConfigMetadata('apiName', true, 2 /* Body */, 0 /* String */),
3385
3689
  generateParamConfigMetadata('childRelationships', true, 2 /* Body */, 4 /* Unsupported */),
3386
- generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */, true),
3690
+ generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */),
3387
3691
  generateParamConfigMetadata('id', false, 2 /* Body */, 0 /* String */),
3388
- generateParamConfigMetadata('isStandard', true, 2 /* Body */, 1 /* Boolean */),
3389
3692
  ];
3390
- const createPromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$4, createPromptTemplateVersion_ConfigPropertyMetadata);
3391
- const createResourceParams$4 = /*#__PURE__*/ createResourceParams$a(createPromptTemplateVersion_ConfigPropertyMetadata);
3392
- function typeCheckConfig$4(untrustedConfig) {
3693
+ const createPromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$b, createPromptTemplateVersion_ConfigPropertyMetadata);
3694
+ const createResourceParams$b = /*#__PURE__*/ createResourceParams$h(createPromptTemplateVersion_ConfigPropertyMetadata);
3695
+ function typeCheckConfig$b(untrustedConfig) {
3393
3696
  const config = {};
3394
- typeCheckConfig$a(untrustedConfig, config, createPromptTemplateVersion_ConfigPropertyMetadata);
3697
+ typeCheckConfig$h(untrustedConfig, config, createPromptTemplateVersion_ConfigPropertyMetadata);
3395
3698
  const untrustedConfig_childRelationships = untrustedConfig.childRelationships;
3396
3699
  if (untrustedIsObject(untrustedConfig_childRelationships)) {
3397
3700
  const untrustedConfig_childRelationships_object = {};
@@ -3408,53 +3711,46 @@ function typeCheckConfig$4(untrustedConfig) {
3408
3711
  }
3409
3712
  }
3410
3713
  const untrustedConfig_fields = untrustedConfig.fields;
3411
- if (ArrayIsArray$1(untrustedConfig_fields)) {
3412
- const untrustedConfig_fields_array = [];
3413
- for (let i = 0, arrayLength = untrustedConfig_fields.length; i < arrayLength; i++) {
3414
- const untrustedConfig_fields_item = untrustedConfig_fields[i];
3415
- if (untrustedIsObject(untrustedConfig_fields_item)) {
3416
- const untrustedConfig_fields_item_object = {};
3417
- const untrustedConfig_fields_item_keys = Object.keys(untrustedConfig_fields_item);
3418
- for (let i = 0, arrayLength = untrustedConfig_fields_item_keys.length; i < arrayLength; i++) {
3419
- const key = untrustedConfig_fields_item_keys[i];
3420
- const untrustedConfig_fields_item_prop = untrustedConfig_fields_item[key];
3421
- if (untrustedConfig_fields_item_object !== undefined) {
3422
- untrustedConfig_fields_item_object[key] = untrustedConfig_fields_item_prop;
3423
- }
3424
- }
3425
- if (untrustedConfig_fields_item_object !== undefined && Object.keys(untrustedConfig_fields_item_object).length >= 0) {
3426
- untrustedConfig_fields_array.push(untrustedConfig_fields_item_object);
3427
- }
3714
+ if (untrustedIsObject(untrustedConfig_fields)) {
3715
+ const untrustedConfig_fields_object = {};
3716
+ const untrustedConfig_fields_keys = Object.keys(untrustedConfig_fields);
3717
+ for (let i = 0, arrayLength = untrustedConfig_fields_keys.length; i < arrayLength; i++) {
3718
+ const key = untrustedConfig_fields_keys[i];
3719
+ const untrustedConfig_fields_prop = untrustedConfig_fields[key];
3720
+ if (untrustedConfig_fields_object !== undefined) {
3721
+ untrustedConfig_fields_object[key] = untrustedConfig_fields_prop;
3428
3722
  }
3429
3723
  }
3430
- config.fields = untrustedConfig_fields_array;
3724
+ if (untrustedConfig_fields_object !== undefined && Object.keys(untrustedConfig_fields_object).length >= 0) {
3725
+ config.fields = untrustedConfig_fields_object;
3726
+ }
3431
3727
  }
3432
3728
  return config;
3433
3729
  }
3434
- function validateAdapterConfig$4(untrustedConfig, configPropertyNames) {
3730
+ function validateAdapterConfig$b(untrustedConfig, configPropertyNames) {
3435
3731
  if (!untrustedIsObject(untrustedConfig)) {
3436
3732
  return null;
3437
3733
  }
3438
3734
  if (process.env.NODE_ENV !== 'production') {
3439
3735
  validateConfig(untrustedConfig, configPropertyNames);
3440
3736
  }
3441
- const config = typeCheckConfig$4(untrustedConfig);
3737
+ const config = typeCheckConfig$b(untrustedConfig);
3442
3738
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
3443
3739
  return null;
3444
3740
  }
3445
3741
  return config;
3446
3742
  }
3447
- function buildNetworkSnapshot$4(luvio, config, options) {
3448
- const resourceParams = createResourceParams$4(config);
3449
- const request = createResourceRequest$4(resourceParams);
3743
+ function buildNetworkSnapshot$b(luvio, config, options) {
3744
+ const resourceParams = createResourceParams$b(config);
3745
+ const request = createResourceRequest$b(resourceParams);
3450
3746
  return luvio.dispatchResourceRequest(request, options)
3451
3747
  .then((response) => {
3452
3748
  return luvio.handleSuccessResponse(() => {
3453
- const snapshot = ingestSuccess$4(luvio, resourceParams, response);
3749
+ const snapshot = ingestSuccess$b(luvio, resourceParams, response);
3454
3750
  return luvio.storeBroadcast().then(() => snapshot);
3455
3751
  }, () => {
3456
3752
  const cache = new StoreKeyMap();
3457
- getResponseCacheKeys$4(cache, luvio, resourceParams, response.body);
3753
+ getResponseCacheKeys$b(cache, luvio, resourceParams, response.body);
3458
3754
  return cache;
3459
3755
  });
3460
3756
  }, (response) => {
@@ -3464,163 +3760,1237 @@ function buildNetworkSnapshot$4(luvio, config, options) {
3464
3760
  }
3465
3761
  const createPromptTemplateVersionAdapterFactory = (luvio) => {
3466
3762
  return function createPromptTemplateVersion(untrustedConfig) {
3467
- const config = validateAdapterConfig$4(untrustedConfig, createPromptTemplateVersion_ConfigPropertyNames);
3763
+ const config = validateAdapterConfig$b(untrustedConfig, createPromptTemplateVersion_ConfigPropertyNames);
3468
3764
  // Invalid or incomplete config
3469
3765
  if (config === null) {
3470
3766
  throw new Error('Invalid config for "createPromptTemplateVersion"');
3471
3767
  }
3472
- return buildNetworkSnapshot$4(luvio, config);
3768
+ return buildNetworkSnapshot$b(luvio, config);
3473
3769
  };
3474
3770
  };
3475
3771
 
3476
- const VERSION$4 = "b513bbac1672327d8eaaf120660e94b5";
3477
- function validate$5(obj, path = 'EinsteinPromptTemplateSupportedLanguageErrorRepresentation') {
3772
+ function validate$b(obj, path = 'PromptTemplateDataProviderOutputParamRepresentation') {
3478
3773
  const v_error = (() => {
3479
3774
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
3480
3775
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
3481
3776
  }
3482
- const obj_errorMessage = obj.errorMessage;
3483
- const path_errorMessage = path + '.errorMessage';
3484
- if (typeof obj_errorMessage !== 'string') {
3485
- return new TypeError('Expected "string" but received "' + typeof obj_errorMessage + '" (at "' + path_errorMessage + '")');
3777
+ const obj_apiName = obj.apiName;
3778
+ const path_apiName = path + '.apiName';
3779
+ if (typeof obj_apiName !== 'string') {
3780
+ return new TypeError('Expected "string" but received "' + typeof obj_apiName + '" (at "' + path_apiName + '")');
3486
3781
  }
3487
- const obj_messageCode = obj.messageCode;
3488
- const path_messageCode = path + '.messageCode';
3489
- if (typeof obj_messageCode !== 'string') {
3490
- return new TypeError('Expected "string" but received "' + typeof obj_messageCode + '" (at "' + path_messageCode + '")');
3782
+ const obj_label = obj.label;
3783
+ const path_label = path + '.label';
3784
+ if (typeof obj_label !== 'string') {
3785
+ return new TypeError('Expected "string" but received "' + typeof obj_label + '" (at "' + path_label + '")');
3491
3786
  }
3492
3787
  })();
3493
3788
  return v_error === undefined ? null : v_error;
3494
3789
  }
3495
- const select$8 = function EinsteinPromptTemplateSupportedLanguageErrorRepresentationSelect() {
3496
- return {
3497
- kind: 'Fragment',
3498
- version: VERSION$4,
3499
- private: [],
3500
- selections: [
3501
- {
3502
- name: 'errorMessage',
3503
- kind: 'Scalar'
3504
- },
3505
- {
3506
- name: 'messageCode',
3507
- kind: 'Scalar'
3508
- }
3509
- ]
3510
- };
3511
- };
3512
- function equals$4(existing, incoming) {
3513
- const existing_errorMessage = existing.errorMessage;
3514
- const incoming_errorMessage = incoming.errorMessage;
3515
- if (!(existing_errorMessage === incoming_errorMessage)) {
3516
- return false;
3517
- }
3518
- const existing_messageCode = existing.messageCode;
3519
- const incoming_messageCode = incoming.messageCode;
3520
- if (!(existing_messageCode === incoming_messageCode)) {
3521
- return false;
3522
- }
3523
- return true;
3524
- }
3525
3790
 
3526
- const VERSION$3 = "65a17d345c28eeca91872a73d8ffe9fd";
3527
- function validate$4(obj, path = 'EinsteinPromptTemplateSupportedLanguageRepresentation') {
3791
+ function validate$a(obj, path = 'PromptTemplateDataProviderInputParamRepresentation') {
3528
3792
  const v_error = (() => {
3529
3793
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
3530
3794
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
3531
3795
  }
3532
- const obj_languageCode = obj.languageCode;
3533
- const path_languageCode = path + '.languageCode';
3534
- if (typeof obj_languageCode !== 'string') {
3535
- return new TypeError('Expected "string" but received "' + typeof obj_languageCode + '" (at "' + path_languageCode + '")');
3796
+ const obj_apiName = obj.apiName;
3797
+ const path_apiName = path + '.apiName';
3798
+ if (typeof obj_apiName !== 'string') {
3799
+ return new TypeError('Expected "string" but received "' + typeof obj_apiName + '" (at "' + path_apiName + '")');
3536
3800
  }
3537
- const obj_languageDisplayName = obj.languageDisplayName;
3538
- const path_languageDisplayName = path + '.languageDisplayName';
3539
- if (typeof obj_languageDisplayName !== 'string') {
3540
- return new TypeError('Expected "string" but received "' + typeof obj_languageDisplayName + '" (at "' + path_languageDisplayName + '")');
3801
+ const obj_label = obj.label;
3802
+ const path_label = path + '.label';
3803
+ if (typeof obj_label !== 'string') {
3804
+ return new TypeError('Expected "string" but received "' + typeof obj_label + '" (at "' + path_label + '")');
3805
+ }
3806
+ const obj_required = obj.required;
3807
+ const path_required = path + '.required';
3808
+ if (typeof obj_required !== 'boolean') {
3809
+ return new TypeError('Expected "boolean" but received "' + typeof obj_required + '" (at "' + path_required + '")');
3810
+ }
3811
+ const obj_type = obj.type;
3812
+ const path_type = path + '.type';
3813
+ if (typeof obj_type !== 'string') {
3814
+ return new TypeError('Expected "string" but received "' + typeof obj_type + '" (at "' + path_type + '")');
3541
3815
  }
3542
3816
  })();
3543
3817
  return v_error === undefined ? null : v_error;
3544
3818
  }
3545
- const select$7 = function EinsteinPromptTemplateSupportedLanguageRepresentationSelect() {
3546
- return {
3547
- kind: 'Fragment',
3548
- version: VERSION$3,
3549
- private: [],
3550
- selections: [
3551
- {
3552
- name: 'languageCode',
3553
- kind: 'Scalar'
3554
- },
3555
- {
3556
- name: 'languageDisplayName',
3557
- kind: 'Scalar'
3558
- }
3559
- ]
3560
- };
3561
- };
3562
- function equals$3(existing, incoming) {
3563
- const existing_languageCode = existing.languageCode;
3564
- const incoming_languageCode = incoming.languageCode;
3565
- if (!(existing_languageCode === incoming_languageCode)) {
3566
- return false;
3567
- }
3568
- const existing_languageDisplayName = existing.languageDisplayName;
3569
- const incoming_languageDisplayName = incoming.languageDisplayName;
3570
- if (!(existing_languageDisplayName === incoming_languageDisplayName)) {
3571
- return false;
3572
- }
3573
- return true;
3574
- }
3575
3819
 
3576
- const TTL$2 = 100;
3577
- const VERSION$2 = "c635f260bce9a11f7c3bf31d60f42b53";
3578
- function validate$3(obj, path = 'EinsteinPromptTemplateVersionOutputLanguagesRepresentation') {
3820
+ const TTL$5 = 300;
3821
+ const VERSION$7 = "d4824d8c6e7848df0de89295e6d9d434";
3822
+ function validate$9(obj, path = 'PromptTemplateDataProviderInstanceConfigRepresentation') {
3579
3823
  const v_error = (() => {
3580
3824
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
3581
3825
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
3582
3826
  }
3583
- const obj_errors = obj.errors;
3584
- const path_errors = path + '.errors';
3585
- if (!ArrayIsArray(obj_errors)) {
3586
- return new TypeError('Expected "array" but received "' + typeof obj_errors + '" (at "' + path_errors + '")');
3827
+ const obj_apiName = obj.apiName;
3828
+ const path_apiName = path + '.apiName';
3829
+ if (typeof obj_apiName !== 'string') {
3830
+ return new TypeError('Expected "string" but received "' + typeof obj_apiName + '" (at "' + path_apiName + '")');
3831
+ }
3832
+ if (obj.dataProviderBundle !== undefined) {
3833
+ const obj_dataProviderBundle = obj.dataProviderBundle;
3834
+ const path_dataProviderBundle = path + '.dataProviderBundle';
3835
+ if (typeof obj_dataProviderBundle !== 'object' || ArrayIsArray(obj_dataProviderBundle) || obj_dataProviderBundle === null) {
3836
+ return new TypeError('Expected "object" but received "' + typeof obj_dataProviderBundle + '" (at "' + path_dataProviderBundle + '")');
3837
+ }
3838
+ const obj_dataProviderBundle_keys = ObjectKeys(obj_dataProviderBundle);
3839
+ for (let i = 0; i < obj_dataProviderBundle_keys.length; i++) {
3840
+ const key = obj_dataProviderBundle_keys[i];
3841
+ const obj_dataProviderBundle_prop = obj_dataProviderBundle[key];
3842
+ const path_dataProviderBundle_prop = path_dataProviderBundle + '["' + key + '"]';
3843
+ if (obj_dataProviderBundle_prop === undefined) {
3844
+ return new TypeError('Expected "defined" but received "' + typeof obj_dataProviderBundle_prop + '" (at "' + path_dataProviderBundle_prop + '")');
3845
+ }
3846
+ }
3587
3847
  }
3588
- for (let i = 0; i < obj_errors.length; i++) {
3589
- const obj_errors_item = obj_errors[i];
3590
- const path_errors_item = path_errors + '[' + i + ']';
3591
- const referencepath_errors_itemValidationError = validate$5(obj_errors_item, path_errors_item);
3592
- if (referencepath_errors_itemValidationError !== null) {
3593
- let message = 'Object doesn\'t match EinsteinPromptTemplateSupportedLanguageErrorRepresentation (at "' + path_errors_item + '")\n';
3594
- message += referencepath_errors_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
3848
+ if (obj.defaultOutputParam !== undefined) {
3849
+ const obj_defaultOutputParam = obj.defaultOutputParam;
3850
+ const path_defaultOutputParam = path + '.defaultOutputParam';
3851
+ const referencepath_defaultOutputParamValidationError = validate$b(obj_defaultOutputParam, path_defaultOutputParam);
3852
+ if (referencepath_defaultOutputParamValidationError !== null) {
3853
+ let message = 'Object doesn\'t match PromptTemplateDataProviderOutputParamRepresentation (at "' + path_defaultOutputParam + '")\n';
3854
+ message += referencepath_defaultOutputParamValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
3595
3855
  return new TypeError(message);
3596
3856
  }
3597
3857
  }
3598
- const obj_isSuccess = obj.isSuccess;
3599
- const path_isSuccess = path + '.isSuccess';
3600
- if (typeof obj_isSuccess !== 'boolean') {
3601
- return new TypeError('Expected "boolean" but received "' + typeof obj_isSuccess + '" (at "' + path_isSuccess + '")');
3858
+ const obj_definition = obj.definition;
3859
+ const path_definition = path + '.definition';
3860
+ if (typeof obj_definition !== 'string') {
3861
+ return new TypeError('Expected "string" but received "' + typeof obj_definition + '" (at "' + path_definition + '")');
3602
3862
  }
3603
- const obj_promptTemplateDevName = obj.promptTemplateDevName;
3604
- const path_promptTemplateDevName = path + '.promptTemplateDevName';
3605
- if (typeof obj_promptTemplateDevName !== 'string') {
3606
- return new TypeError('Expected "string" but received "' + typeof obj_promptTemplateDevName + '" (at "' + path_promptTemplateDevName + '")');
3863
+ if (obj.description !== undefined) {
3864
+ const obj_description = obj.description;
3865
+ const path_description = path + '.description';
3866
+ let obj_description_union0 = null;
3867
+ const obj_description_union0_error = (() => {
3868
+ if (typeof obj_description !== 'string') {
3869
+ return new TypeError('Expected "string" but received "' + typeof obj_description + '" (at "' + path_description + '")');
3870
+ }
3871
+ })();
3872
+ if (obj_description_union0_error != null) {
3873
+ obj_description_union0 = obj_description_union0_error.message;
3874
+ }
3875
+ let obj_description_union1 = null;
3876
+ const obj_description_union1_error = (() => {
3877
+ if (obj_description !== null) {
3878
+ return new TypeError('Expected "null" but received "' + typeof obj_description + '" (at "' + path_description + '")');
3879
+ }
3880
+ })();
3881
+ if (obj_description_union1_error != null) {
3882
+ obj_description_union1 = obj_description_union1_error.message;
3883
+ }
3884
+ if (obj_description_union0 && obj_description_union1) {
3885
+ let message = 'Object doesn\'t match union (at "' + path_description + '")';
3886
+ message += '\n' + obj_description_union0.split('\n').map((line) => '\t' + line).join('\n');
3887
+ message += '\n' + obj_description_union1.split('\n').map((line) => '\t' + line).join('\n');
3888
+ return new TypeError(message);
3889
+ }
3607
3890
  }
3608
- const obj_supportedLanguages = obj.supportedLanguages;
3609
- const path_supportedLanguages = path + '.supportedLanguages';
3610
- if (!ArrayIsArray(obj_supportedLanguages)) {
3611
- return new TypeError('Expected "array" but received "' + typeof obj_supportedLanguages + '" (at "' + path_supportedLanguages + '")');
3891
+ const obj_groupName = obj.groupName;
3892
+ const path_groupName = path + '.groupName';
3893
+ if (typeof obj_groupName !== 'string') {
3894
+ return new TypeError('Expected "string" but received "' + typeof obj_groupName + '" (at "' + path_groupName + '")');
3895
+ }
3896
+ if (obj.inputParams !== undefined) {
3897
+ const obj_inputParams = obj.inputParams;
3898
+ const path_inputParams = path + '.inputParams';
3899
+ if (!ArrayIsArray(obj_inputParams)) {
3900
+ return new TypeError('Expected "array" but received "' + typeof obj_inputParams + '" (at "' + path_inputParams + '")');
3901
+ }
3902
+ for (let i = 0; i < obj_inputParams.length; i++) {
3903
+ const obj_inputParams_item = obj_inputParams[i];
3904
+ const path_inputParams_item = path_inputParams + '[' + i + ']';
3905
+ const referencepath_inputParams_itemValidationError = validate$a(obj_inputParams_item, path_inputParams_item);
3906
+ if (referencepath_inputParams_itemValidationError !== null) {
3907
+ let message = 'Object doesn\'t match PromptTemplateDataProviderInputParamRepresentation (at "' + path_inputParams_item + '")\n';
3908
+ message += referencepath_inputParams_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
3909
+ return new TypeError(message);
3910
+ }
3911
+ }
3612
3912
  }
3613
- for (let i = 0; i < obj_supportedLanguages.length; i++) {
3614
- const obj_supportedLanguages_item = obj_supportedLanguages[i];
3615
- const path_supportedLanguages_item = path_supportedLanguages + '[' + i + ']';
3616
- const referencepath_supportedLanguages_itemValidationError = validate$4(obj_supportedLanguages_item, path_supportedLanguages_item);
3617
- if (referencepath_supportedLanguages_itemValidationError !== null) {
3618
- let message = 'Object doesn\'t match EinsteinPromptTemplateSupportedLanguageRepresentation (at "' + path_supportedLanguages_item + '")\n';
3619
- message += referencepath_supportedLanguages_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
3913
+ const obj_label = obj.label;
3914
+ const path_label = path + '.label';
3915
+ if (typeof obj_label !== 'string') {
3916
+ return new TypeError('Expected "string" but received "' + typeof obj_label + '" (at "' + path_label + '")');
3917
+ }
3918
+ if (obj.mappedInputs !== undefined) {
3919
+ const obj_mappedInputs = obj.mappedInputs;
3920
+ const path_mappedInputs = path + '.mappedInputs';
3921
+ if (typeof obj_mappedInputs !== 'object' || ArrayIsArray(obj_mappedInputs) || obj_mappedInputs === null) {
3922
+ return new TypeError('Expected "object" but received "' + typeof obj_mappedInputs + '" (at "' + path_mappedInputs + '")');
3923
+ }
3924
+ const obj_mappedInputs_keys = ObjectKeys(obj_mappedInputs);
3925
+ for (let i = 0; i < obj_mappedInputs_keys.length; i++) {
3926
+ const key = obj_mappedInputs_keys[i];
3927
+ const obj_mappedInputs_prop = obj_mappedInputs[key];
3928
+ const path_mappedInputs_prop = path_mappedInputs + '["' + key + '"]';
3929
+ if (obj_mappedInputs_prop === undefined) {
3930
+ return new TypeError('Expected "defined" but received "' + typeof obj_mappedInputs_prop + '" (at "' + path_mappedInputs_prop + '")');
3931
+ }
3932
+ }
3933
+ }
3934
+ if (obj.nodeIcon !== undefined) {
3935
+ const obj_nodeIcon = obj.nodeIcon;
3936
+ const path_nodeIcon = path + '.nodeIcon';
3937
+ let obj_nodeIcon_union0 = null;
3938
+ const obj_nodeIcon_union0_error = (() => {
3939
+ if (typeof obj_nodeIcon !== 'string') {
3940
+ return new TypeError('Expected "string" but received "' + typeof obj_nodeIcon + '" (at "' + path_nodeIcon + '")');
3941
+ }
3942
+ })();
3943
+ if (obj_nodeIcon_union0_error != null) {
3944
+ obj_nodeIcon_union0 = obj_nodeIcon_union0_error.message;
3945
+ }
3946
+ let obj_nodeIcon_union1 = null;
3947
+ const obj_nodeIcon_union1_error = (() => {
3948
+ if (obj_nodeIcon !== null) {
3949
+ return new TypeError('Expected "null" but received "' + typeof obj_nodeIcon + '" (at "' + path_nodeIcon + '")');
3950
+ }
3951
+ })();
3952
+ if (obj_nodeIcon_union1_error != null) {
3953
+ obj_nodeIcon_union1 = obj_nodeIcon_union1_error.message;
3954
+ }
3955
+ if (obj_nodeIcon_union0 && obj_nodeIcon_union1) {
3956
+ let message = 'Object doesn\'t match union (at "' + path_nodeIcon + '")';
3957
+ message += '\n' + obj_nodeIcon_union0.split('\n').map((line) => '\t' + line).join('\n');
3958
+ message += '\n' + obj_nodeIcon_union1.split('\n').map((line) => '\t' + line).join('\n');
3620
3959
  return new TypeError(message);
3621
3960
  }
3622
3961
  }
3623
- const obj_versionId = obj.versionId;
3962
+ if (obj.outputParams !== undefined) {
3963
+ const obj_outputParams = obj.outputParams;
3964
+ const path_outputParams = path + '.outputParams';
3965
+ if (!ArrayIsArray(obj_outputParams)) {
3966
+ return new TypeError('Expected "array" but received "' + typeof obj_outputParams + '" (at "' + path_outputParams + '")');
3967
+ }
3968
+ for (let i = 0; i < obj_outputParams.length; i++) {
3969
+ const obj_outputParams_item = obj_outputParams[i];
3970
+ const path_outputParams_item = path_outputParams + '[' + i + ']';
3971
+ const referencepath_outputParams_itemValidationError = validate$b(obj_outputParams_item, path_outputParams_item);
3972
+ if (referencepath_outputParams_itemValidationError !== null) {
3973
+ let message = 'Object doesn\'t match PromptTemplateDataProviderOutputParamRepresentation (at "' + path_outputParams_item + '")\n';
3974
+ message += referencepath_outputParams_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
3975
+ return new TypeError(message);
3976
+ }
3977
+ }
3978
+ }
3979
+ const obj_referenceName = obj.referenceName;
3980
+ const path_referenceName = path + '.referenceName';
3981
+ if (typeof obj_referenceName !== 'string') {
3982
+ return new TypeError('Expected "string" but received "' + typeof obj_referenceName + '" (at "' + path_referenceName + '")');
3983
+ }
3984
+ if (obj.scopedToTarget !== undefined) {
3985
+ const obj_scopedToTarget = obj.scopedToTarget;
3986
+ const path_scopedToTarget = path + '.scopedToTarget';
3987
+ let obj_scopedToTarget_union0 = null;
3988
+ const obj_scopedToTarget_union0_error = (() => {
3989
+ if (typeof obj_scopedToTarget !== 'string') {
3990
+ return new TypeError('Expected "string" but received "' + typeof obj_scopedToTarget + '" (at "' + path_scopedToTarget + '")');
3991
+ }
3992
+ })();
3993
+ if (obj_scopedToTarget_union0_error != null) {
3994
+ obj_scopedToTarget_union0 = obj_scopedToTarget_union0_error.message;
3995
+ }
3996
+ let obj_scopedToTarget_union1 = null;
3997
+ const obj_scopedToTarget_union1_error = (() => {
3998
+ if (obj_scopedToTarget !== null) {
3999
+ return new TypeError('Expected "null" but received "' + typeof obj_scopedToTarget + '" (at "' + path_scopedToTarget + '")');
4000
+ }
4001
+ })();
4002
+ if (obj_scopedToTarget_union1_error != null) {
4003
+ obj_scopedToTarget_union1 = obj_scopedToTarget_union1_error.message;
4004
+ }
4005
+ if (obj_scopedToTarget_union0 && obj_scopedToTarget_union1) {
4006
+ let message = 'Object doesn\'t match union (at "' + path_scopedToTarget + '")';
4007
+ message += '\n' + obj_scopedToTarget_union0.split('\n').map((line) => '\t' + line).join('\n');
4008
+ message += '\n' + obj_scopedToTarget_union1.split('\n').map((line) => '\t' + line).join('\n');
4009
+ return new TypeError(message);
4010
+ }
4011
+ }
4012
+ if (obj.subGroup !== undefined) {
4013
+ const obj_subGroup = obj.subGroup;
4014
+ const path_subGroup = path + '.subGroup';
4015
+ let obj_subGroup_union0 = null;
4016
+ const obj_subGroup_union0_error = (() => {
4017
+ if (typeof obj_subGroup !== 'string') {
4018
+ return new TypeError('Expected "string" but received "' + typeof obj_subGroup + '" (at "' + path_subGroup + '")');
4019
+ }
4020
+ })();
4021
+ if (obj_subGroup_union0_error != null) {
4022
+ obj_subGroup_union0 = obj_subGroup_union0_error.message;
4023
+ }
4024
+ let obj_subGroup_union1 = null;
4025
+ const obj_subGroup_union1_error = (() => {
4026
+ if (obj_subGroup !== null) {
4027
+ return new TypeError('Expected "null" but received "' + typeof obj_subGroup + '" (at "' + path_subGroup + '")');
4028
+ }
4029
+ })();
4030
+ if (obj_subGroup_union1_error != null) {
4031
+ obj_subGroup_union1 = obj_subGroup_union1_error.message;
4032
+ }
4033
+ if (obj_subGroup_union0 && obj_subGroup_union1) {
4034
+ let message = 'Object doesn\'t match union (at "' + path_subGroup + '")';
4035
+ message += '\n' + obj_subGroup_union0.split('\n').map((line) => '\t' + line).join('\n');
4036
+ message += '\n' + obj_subGroup_union1.split('\n').map((line) => '\t' + line).join('\n');
4037
+ return new TypeError(message);
4038
+ }
4039
+ }
4040
+ })();
4041
+ return v_error === undefined ? null : v_error;
4042
+ }
4043
+ const RepresentationType$5 = 'PromptTemplateDataProviderInstanceConfigRepresentation';
4044
+ function normalize$5(input, existing, path, luvio, store, timestamp) {
4045
+ return input;
4046
+ }
4047
+ const select$i = function PromptTemplateDataProviderInstanceConfigRepresentationSelect() {
4048
+ return {
4049
+ kind: 'Fragment',
4050
+ version: VERSION$7,
4051
+ private: [],
4052
+ opaque: true
4053
+ };
4054
+ };
4055
+ function equals$7(existing, incoming) {
4056
+ if (JSONStringify(incoming) !== JSONStringify(existing)) {
4057
+ return false;
4058
+ }
4059
+ return true;
4060
+ }
4061
+ const ingest$5 = function PromptTemplateDataProviderInstanceConfigRepresentationIngest(input, path, luvio, store, timestamp) {
4062
+ if (process.env.NODE_ENV !== 'production') {
4063
+ const validateError = validate$9(input);
4064
+ if (validateError !== null) {
4065
+ throw validateError;
4066
+ }
4067
+ }
4068
+ const key = path.fullPath;
4069
+ const ttlToUse = TTL$5;
4070
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$5, "EinsteinLLM", VERSION$7, RepresentationType$5, equals$7);
4071
+ return createLink(key);
4072
+ };
4073
+ function getTypeCacheKeys$5(rootKeySet, luvio, input, fullPathFactory) {
4074
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
4075
+ const rootKey = fullPathFactory();
4076
+ rootKeySet.set(rootKey, {
4077
+ namespace: keyPrefix,
4078
+ representationName: RepresentationType$5,
4079
+ mergeable: false
4080
+ });
4081
+ }
4082
+
4083
+ function select$h(luvio, params) {
4084
+ return select$i();
4085
+ }
4086
+ function keyBuilder$h(luvio, params) {
4087
+ return keyPrefix + '::PromptTemplateDataProviderInstanceConfigRepresentation:(' + stableJSONStringify(params.body.additionalParam) + '::' + 'definition:' + params.body.definition + '::' + 'groupName:' + params.body.groupName + ')';
4088
+ }
4089
+ function getResponseCacheKeys$a(storeKeyMap, luvio, resourceParams, response) {
4090
+ getTypeCacheKeys$5(storeKeyMap, luvio, response, () => keyBuilder$h(luvio, resourceParams));
4091
+ }
4092
+ function ingestSuccess$a(luvio, resourceParams, response, snapshotRefresh) {
4093
+ const { body } = response;
4094
+ const key = keyBuilder$h(luvio, resourceParams);
4095
+ luvio.storeIngest(key, ingest$5, body);
4096
+ const snapshot = luvio.storeLookup({
4097
+ recordId: key,
4098
+ node: select$h(),
4099
+ variables: {},
4100
+ }, snapshotRefresh);
4101
+ if (process.env.NODE_ENV !== 'production') {
4102
+ if (snapshot.state !== 'Fulfilled') {
4103
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
4104
+ }
4105
+ }
4106
+ deepFreeze(snapshot.data);
4107
+ return snapshot;
4108
+ }
4109
+ function ingestError$8(luvio, params, error, snapshotRefresh) {
4110
+ const key = keyBuilder$h(luvio, params);
4111
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
4112
+ const storeMetadataParams = {
4113
+ ttl: TTL$5,
4114
+ namespace: keyPrefix,
4115
+ version: VERSION$7,
4116
+ representationName: RepresentationType$5
4117
+ };
4118
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
4119
+ return errorSnapshot;
4120
+ }
4121
+ function createResourceRequest$a(config) {
4122
+ const headers = {};
4123
+ return {
4124
+ baseUri: '/services/data/v65.0',
4125
+ basePath: '/einstein/prompt-templates/data-provider/describe',
4126
+ method: 'post',
4127
+ body: config.body,
4128
+ urlParams: {},
4129
+ queryParams: {},
4130
+ headers,
4131
+ priority: 'normal',
4132
+ };
4133
+ }
4134
+
4135
+ const adapterName$a = 'getDataProviderInstanceConfig';
4136
+ const getDataProviderInstanceConfig_ConfigPropertyMetadata = [
4137
+ generateParamConfigMetadata('additionalParam', false, 2 /* Body */, 4 /* Unsupported */),
4138
+ generateParamConfigMetadata('definition', true, 2 /* Body */, 0 /* String */),
4139
+ generateParamConfigMetadata('groupName', true, 2 /* Body */, 0 /* String */),
4140
+ ];
4141
+ const getDataProviderInstanceConfig_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$a, getDataProviderInstanceConfig_ConfigPropertyMetadata);
4142
+ const createResourceParams$a = /*#__PURE__*/ createResourceParams$h(getDataProviderInstanceConfig_ConfigPropertyMetadata);
4143
+ function keyBuilder$g(luvio, config) {
4144
+ const resourceParams = createResourceParams$a(config);
4145
+ return keyBuilder$h(luvio, resourceParams);
4146
+ }
4147
+ function typeCheckConfig$a(untrustedConfig) {
4148
+ const config = {};
4149
+ typeCheckConfig$h(untrustedConfig, config, getDataProviderInstanceConfig_ConfigPropertyMetadata);
4150
+ const untrustedConfig_additionalParam = untrustedConfig.additionalParam;
4151
+ if (untrustedIsObject(untrustedConfig_additionalParam)) {
4152
+ const untrustedConfig_additionalParam_object = {};
4153
+ const untrustedConfig_additionalParam_keys = Object.keys(untrustedConfig_additionalParam);
4154
+ for (let i = 0, arrayLength = untrustedConfig_additionalParam_keys.length; i < arrayLength; i++) {
4155
+ const key = untrustedConfig_additionalParam_keys[i];
4156
+ const untrustedConfig_additionalParam_prop = untrustedConfig_additionalParam[key];
4157
+ if (untrustedConfig_additionalParam_object !== undefined) {
4158
+ untrustedConfig_additionalParam_object[key] = untrustedConfig_additionalParam_prop;
4159
+ }
4160
+ }
4161
+ if (untrustedConfig_additionalParam_object !== undefined && Object.keys(untrustedConfig_additionalParam_object).length >= 0) {
4162
+ config.additionalParam = untrustedConfig_additionalParam_object;
4163
+ }
4164
+ }
4165
+ return config;
4166
+ }
4167
+ function validateAdapterConfig$a(untrustedConfig, configPropertyNames) {
4168
+ if (!untrustedIsObject(untrustedConfig)) {
4169
+ return null;
4170
+ }
4171
+ if (process.env.NODE_ENV !== 'production') {
4172
+ validateConfig(untrustedConfig, configPropertyNames);
4173
+ }
4174
+ const config = typeCheckConfig$a(untrustedConfig);
4175
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
4176
+ return null;
4177
+ }
4178
+ return config;
4179
+ }
4180
+ function adapterFragment$8(luvio, config) {
4181
+ createResourceParams$a(config);
4182
+ return select$h();
4183
+ }
4184
+ function onFetchResponseSuccess$8(luvio, config, resourceParams, response) {
4185
+ const snapshot = ingestSuccess$a(luvio, resourceParams, response, {
4186
+ config,
4187
+ resolve: () => buildNetworkSnapshot$a(luvio, config, snapshotRefreshOptions)
4188
+ });
4189
+ return luvio.storeBroadcast().then(() => snapshot);
4190
+ }
4191
+ function onFetchResponseError$8(luvio, config, resourceParams, response) {
4192
+ const snapshot = ingestError$8(luvio, resourceParams, response, {
4193
+ config,
4194
+ resolve: () => buildNetworkSnapshot$a(luvio, config, snapshotRefreshOptions)
4195
+ });
4196
+ return luvio.storeBroadcast().then(() => snapshot);
4197
+ }
4198
+ function buildNetworkSnapshot$a(luvio, config, options) {
4199
+ const resourceParams = createResourceParams$a(config);
4200
+ const request = createResourceRequest$a(resourceParams);
4201
+ return luvio.dispatchResourceRequest(request, options)
4202
+ .then((response) => {
4203
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$8(luvio, config, resourceParams, response), () => {
4204
+ const cache = new StoreKeyMap();
4205
+ getResponseCacheKeys$a(cache, luvio, resourceParams, response.body);
4206
+ return cache;
4207
+ });
4208
+ }, (response) => {
4209
+ return luvio.handleErrorResponse(() => onFetchResponseError$8(luvio, config, resourceParams, response));
4210
+ });
4211
+ }
4212
+ function buildNetworkSnapshotCachePolicy$8(context, coercedAdapterRequestContext) {
4213
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$a, 'get', false);
4214
+ }
4215
+ function buildCachedSnapshotCachePolicy$8(context, storeLookup) {
4216
+ const { luvio, config } = context;
4217
+ const selector = {
4218
+ recordId: keyBuilder$g(luvio, config),
4219
+ node: adapterFragment$8(luvio, config),
4220
+ variables: {},
4221
+ };
4222
+ const cacheSnapshot = storeLookup(selector, {
4223
+ config,
4224
+ resolve: () => buildNetworkSnapshot$a(luvio, config, snapshotRefreshOptions)
4225
+ });
4226
+ return cacheSnapshot;
4227
+ }
4228
+ const getDataProviderInstanceConfigAdapterFactory = (luvio) => function EinsteinLLM__getDataProviderInstanceConfig(untrustedConfig, requestContext) {
4229
+ const config = validateAdapterConfig$a(untrustedConfig, getDataProviderInstanceConfig_ConfigPropertyNames);
4230
+ // Invalid or incomplete config
4231
+ if (config === null) {
4232
+ return null;
4233
+ }
4234
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
4235
+ buildCachedSnapshotCachePolicy$8, buildNetworkSnapshotCachePolicy$8);
4236
+ };
4237
+
4238
+ function validate$8(obj, path = 'PromptTemplateDataProviderTypeConfigRepresentation') {
4239
+ const v_error = (() => {
4240
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
4241
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
4242
+ }
4243
+ if (obj.description !== undefined) {
4244
+ const obj_description = obj.description;
4245
+ const path_description = path + '.description';
4246
+ if (typeof obj_description !== 'string') {
4247
+ return new TypeError('Expected "string" but received "' + typeof obj_description + '" (at "' + path_description + '")');
4248
+ }
4249
+ }
4250
+ const obj_groupName = obj.groupName;
4251
+ const path_groupName = path + '.groupName';
4252
+ if (typeof obj_groupName !== 'string') {
4253
+ return new TypeError('Expected "string" but received "' + typeof obj_groupName + '" (at "' + path_groupName + '")');
4254
+ }
4255
+ const obj_icon = obj.icon;
4256
+ const path_icon = path + '.icon';
4257
+ if (typeof obj_icon !== 'string') {
4258
+ return new TypeError('Expected "string" but received "' + typeof obj_icon + '" (at "' + path_icon + '")');
4259
+ }
4260
+ const obj_isTopLevel = obj.isTopLevel;
4261
+ const path_isTopLevel = path + '.isTopLevel';
4262
+ if (typeof obj_isTopLevel !== 'boolean') {
4263
+ return new TypeError('Expected "boolean" but received "' + typeof obj_isTopLevel + '" (at "' + path_isTopLevel + '")');
4264
+ }
4265
+ const obj_label = obj.label;
4266
+ const path_label = path + '.label';
4267
+ if (typeof obj_label !== 'string') {
4268
+ return new TypeError('Expected "string" but received "' + typeof obj_label + '" (at "' + path_label + '")');
4269
+ }
4270
+ if (obj.parentNode !== undefined) {
4271
+ const obj_parentNode = obj.parentNode;
4272
+ const path_parentNode = path + '.parentNode';
4273
+ if (typeof obj_parentNode !== 'string') {
4274
+ return new TypeError('Expected "string" but received "' + typeof obj_parentNode + '" (at "' + path_parentNode + '")');
4275
+ }
4276
+ }
4277
+ if (obj.scope !== undefined) {
4278
+ const obj_scope = obj.scope;
4279
+ const path_scope = path + '.scope';
4280
+ if (obj_scope === undefined) {
4281
+ return new TypeError('Expected "defined" but received "' + typeof obj_scope + '" (at "' + path_scope + '")');
4282
+ }
4283
+ }
4284
+ })();
4285
+ return v_error === undefined ? null : v_error;
4286
+ }
4287
+
4288
+ const TTL$4 = 300;
4289
+ const VERSION$6 = "212332dac1decc071b476742df3440fb";
4290
+ function validate$7(obj, path = 'PromptTemplateDataProviderTypeConfigCollectionRepresentation') {
4291
+ const v_error = (() => {
4292
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
4293
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
4294
+ }
4295
+ const obj_dataProviderTypeConfigs = obj.dataProviderTypeConfigs;
4296
+ const path_dataProviderTypeConfigs = path + '.dataProviderTypeConfigs';
4297
+ if (!ArrayIsArray(obj_dataProviderTypeConfigs)) {
4298
+ return new TypeError('Expected "array" but received "' + typeof obj_dataProviderTypeConfigs + '" (at "' + path_dataProviderTypeConfigs + '")');
4299
+ }
4300
+ for (let i = 0; i < obj_dataProviderTypeConfigs.length; i++) {
4301
+ const obj_dataProviderTypeConfigs_item = obj_dataProviderTypeConfigs[i];
4302
+ const path_dataProviderTypeConfigs_item = path_dataProviderTypeConfigs + '[' + i + ']';
4303
+ const referencepath_dataProviderTypeConfigs_itemValidationError = validate$8(obj_dataProviderTypeConfigs_item, path_dataProviderTypeConfigs_item);
4304
+ if (referencepath_dataProviderTypeConfigs_itemValidationError !== null) {
4305
+ let message = 'Object doesn\'t match PromptTemplateDataProviderTypeConfigRepresentation (at "' + path_dataProviderTypeConfigs_item + '")\n';
4306
+ message += referencepath_dataProviderTypeConfigs_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
4307
+ return new TypeError(message);
4308
+ }
4309
+ }
4310
+ })();
4311
+ return v_error === undefined ? null : v_error;
4312
+ }
4313
+ const RepresentationType$4 = 'PromptTemplateDataProviderTypeConfigCollectionRepresentation';
4314
+ function normalize$4(input, existing, path, luvio, store, timestamp) {
4315
+ return input;
4316
+ }
4317
+ const select$g = function PromptTemplateDataProviderTypeConfigCollectionRepresentationSelect() {
4318
+ return {
4319
+ kind: 'Fragment',
4320
+ version: VERSION$6,
4321
+ private: [],
4322
+ opaque: true
4323
+ };
4324
+ };
4325
+ function equals$6(existing, incoming) {
4326
+ if (JSONStringify(incoming) !== JSONStringify(existing)) {
4327
+ return false;
4328
+ }
4329
+ return true;
4330
+ }
4331
+ const ingest$4 = function PromptTemplateDataProviderTypeConfigCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
4332
+ if (process.env.NODE_ENV !== 'production') {
4333
+ const validateError = validate$7(input);
4334
+ if (validateError !== null) {
4335
+ throw validateError;
4336
+ }
4337
+ }
4338
+ const key = path.fullPath;
4339
+ const ttlToUse = TTL$4;
4340
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$4, "EinsteinLLM", VERSION$6, RepresentationType$4, equals$6);
4341
+ return createLink(key);
4342
+ };
4343
+ function getTypeCacheKeys$4(rootKeySet, luvio, input, fullPathFactory) {
4344
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
4345
+ const rootKey = fullPathFactory();
4346
+ rootKeySet.set(rootKey, {
4347
+ namespace: keyPrefix,
4348
+ representationName: RepresentationType$4,
4349
+ mergeable: false
4350
+ });
4351
+ }
4352
+
4353
+ function select$f(luvio, params) {
4354
+ return select$g();
4355
+ }
4356
+ function keyBuilder$f(luvio, params) {
4357
+ return keyPrefix + '::PromptTemplateDataProviderTypeConfigCollectionRepresentation:(' + 'templateType:' + params.urlParams.templateType + ')';
4358
+ }
4359
+ function getResponseCacheKeys$9(storeKeyMap, luvio, resourceParams, response) {
4360
+ getTypeCacheKeys$4(storeKeyMap, luvio, response, () => keyBuilder$f(luvio, resourceParams));
4361
+ }
4362
+ function ingestSuccess$9(luvio, resourceParams, response, snapshotRefresh) {
4363
+ const { body } = response;
4364
+ const key = keyBuilder$f(luvio, resourceParams);
4365
+ luvio.storeIngest(key, ingest$4, body);
4366
+ const snapshot = luvio.storeLookup({
4367
+ recordId: key,
4368
+ node: select$f(),
4369
+ variables: {},
4370
+ }, snapshotRefresh);
4371
+ if (process.env.NODE_ENV !== 'production') {
4372
+ if (snapshot.state !== 'Fulfilled') {
4373
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
4374
+ }
4375
+ }
4376
+ deepFreeze(snapshot.data);
4377
+ return snapshot;
4378
+ }
4379
+ function ingestError$7(luvio, params, error, snapshotRefresh) {
4380
+ const key = keyBuilder$f(luvio, params);
4381
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
4382
+ const storeMetadataParams = {
4383
+ ttl: TTL$4,
4384
+ namespace: keyPrefix,
4385
+ version: VERSION$6,
4386
+ representationName: RepresentationType$4
4387
+ };
4388
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
4389
+ return errorSnapshot;
4390
+ }
4391
+ function createResourceRequest$9(config) {
4392
+ const headers = {};
4393
+ return {
4394
+ baseUri: '/services/data/v65.0',
4395
+ basePath: '/einstein/prompt-templates/data-provider-types/' + config.urlParams.templateType + '',
4396
+ method: 'get',
4397
+ body: null,
4398
+ urlParams: config.urlParams,
4399
+ queryParams: {},
4400
+ headers,
4401
+ priority: 'normal',
4402
+ };
4403
+ }
4404
+
4405
+ const adapterName$9 = 'getDataProviderTypeConfigs';
4406
+ const getDataProviderTypeConfigs_ConfigPropertyMetadata = [
4407
+ generateParamConfigMetadata('templateType', true, 0 /* UrlParameter */, 0 /* String */),
4408
+ ];
4409
+ const getDataProviderTypeConfigs_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$9, getDataProviderTypeConfigs_ConfigPropertyMetadata);
4410
+ const createResourceParams$9 = /*#__PURE__*/ createResourceParams$h(getDataProviderTypeConfigs_ConfigPropertyMetadata);
4411
+ function keyBuilder$e(luvio, config) {
4412
+ const resourceParams = createResourceParams$9(config);
4413
+ return keyBuilder$f(luvio, resourceParams);
4414
+ }
4415
+ function typeCheckConfig$9(untrustedConfig) {
4416
+ const config = {};
4417
+ typeCheckConfig$h(untrustedConfig, config, getDataProviderTypeConfigs_ConfigPropertyMetadata);
4418
+ return config;
4419
+ }
4420
+ function validateAdapterConfig$9(untrustedConfig, configPropertyNames) {
4421
+ if (!untrustedIsObject(untrustedConfig)) {
4422
+ return null;
4423
+ }
4424
+ if (process.env.NODE_ENV !== 'production') {
4425
+ validateConfig(untrustedConfig, configPropertyNames);
4426
+ }
4427
+ const config = typeCheckConfig$9(untrustedConfig);
4428
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
4429
+ return null;
4430
+ }
4431
+ return config;
4432
+ }
4433
+ function adapterFragment$7(luvio, config) {
4434
+ createResourceParams$9(config);
4435
+ return select$f();
4436
+ }
4437
+ function onFetchResponseSuccess$7(luvio, config, resourceParams, response) {
4438
+ const snapshot = ingestSuccess$9(luvio, resourceParams, response, {
4439
+ config,
4440
+ resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
4441
+ });
4442
+ return luvio.storeBroadcast().then(() => snapshot);
4443
+ }
4444
+ function onFetchResponseError$7(luvio, config, resourceParams, response) {
4445
+ const snapshot = ingestError$7(luvio, resourceParams, response, {
4446
+ config,
4447
+ resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
4448
+ });
4449
+ return luvio.storeBroadcast().then(() => snapshot);
4450
+ }
4451
+ function buildNetworkSnapshot$9(luvio, config, options) {
4452
+ const resourceParams = createResourceParams$9(config);
4453
+ const request = createResourceRequest$9(resourceParams);
4454
+ return luvio.dispatchResourceRequest(request, options)
4455
+ .then((response) => {
4456
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$7(luvio, config, resourceParams, response), () => {
4457
+ const cache = new StoreKeyMap();
4458
+ getResponseCacheKeys$9(cache, luvio, resourceParams, response.body);
4459
+ return cache;
4460
+ });
4461
+ }, (response) => {
4462
+ return luvio.handleErrorResponse(() => onFetchResponseError$7(luvio, config, resourceParams, response));
4463
+ });
4464
+ }
4465
+ function buildNetworkSnapshotCachePolicy$7(context, coercedAdapterRequestContext) {
4466
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$9, undefined, false);
4467
+ }
4468
+ function buildCachedSnapshotCachePolicy$7(context, storeLookup) {
4469
+ const { luvio, config } = context;
4470
+ const selector = {
4471
+ recordId: keyBuilder$e(luvio, config),
4472
+ node: adapterFragment$7(luvio, config),
4473
+ variables: {},
4474
+ };
4475
+ const cacheSnapshot = storeLookup(selector, {
4476
+ config,
4477
+ resolve: () => buildNetworkSnapshot$9(luvio, config, snapshotRefreshOptions)
4478
+ });
4479
+ return cacheSnapshot;
4480
+ }
4481
+ const getDataProviderTypeConfigsAdapterFactory = (luvio) => function EinsteinLLM__getDataProviderTypeConfigs(untrustedConfig, requestContext) {
4482
+ const config = validateAdapterConfig$9(untrustedConfig, getDataProviderTypeConfigs_ConfigPropertyNames);
4483
+ // Invalid or incomplete config
4484
+ if (config === null) {
4485
+ return null;
4486
+ }
4487
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
4488
+ buildCachedSnapshotCachePolicy$7, buildNetworkSnapshotCachePolicy$7);
4489
+ };
4490
+
4491
+ const TTL$3 = 300;
4492
+ const VERSION$5 = "3a6ecdfe18eb2af8f8f6aaa1a30b194c";
4493
+ function validate$6(obj, path = 'PromptTemplateDataProviderInstanceConfigCollectionRepresentation') {
4494
+ const v_error = (() => {
4495
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
4496
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
4497
+ }
4498
+ const obj_dataProviderInstanceConfigs = obj.dataProviderInstanceConfigs;
4499
+ const path_dataProviderInstanceConfigs = path + '.dataProviderInstanceConfigs';
4500
+ if (!ArrayIsArray(obj_dataProviderInstanceConfigs)) {
4501
+ return new TypeError('Expected "array" but received "' + typeof obj_dataProviderInstanceConfigs + '" (at "' + path_dataProviderInstanceConfigs + '")');
4502
+ }
4503
+ for (let i = 0; i < obj_dataProviderInstanceConfigs.length; i++) {
4504
+ const obj_dataProviderInstanceConfigs_item = obj_dataProviderInstanceConfigs[i];
4505
+ const path_dataProviderInstanceConfigs_item = path_dataProviderInstanceConfigs + '[' + i + ']';
4506
+ const referencepath_dataProviderInstanceConfigs_itemValidationError = validate$9(obj_dataProviderInstanceConfigs_item, path_dataProviderInstanceConfigs_item);
4507
+ if (referencepath_dataProviderInstanceConfigs_itemValidationError !== null) {
4508
+ let message = 'Object doesn\'t match PromptTemplateDataProviderInstanceConfigRepresentation (at "' + path_dataProviderInstanceConfigs_item + '")\n';
4509
+ message += referencepath_dataProviderInstanceConfigs_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
4510
+ return new TypeError(message);
4511
+ }
4512
+ }
4513
+ })();
4514
+ return v_error === undefined ? null : v_error;
4515
+ }
4516
+ const RepresentationType$3 = 'PromptTemplateDataProviderInstanceConfigCollectionRepresentation';
4517
+ function normalize$3(input, existing, path, luvio, store, timestamp) {
4518
+ return input;
4519
+ }
4520
+ const select$e = function PromptTemplateDataProviderInstanceConfigCollectionRepresentationSelect() {
4521
+ return {
4522
+ kind: 'Fragment',
4523
+ version: VERSION$5,
4524
+ private: [],
4525
+ opaque: true
4526
+ };
4527
+ };
4528
+ function equals$5(existing, incoming) {
4529
+ if (JSONStringify(incoming) !== JSONStringify(existing)) {
4530
+ return false;
4531
+ }
4532
+ return true;
4533
+ }
4534
+ const ingest$3 = function PromptTemplateDataProviderInstanceConfigCollectionRepresentationIngest(input, path, luvio, store, timestamp) {
4535
+ if (process.env.NODE_ENV !== 'production') {
4536
+ const validateError = validate$6(input);
4537
+ if (validateError !== null) {
4538
+ throw validateError;
4539
+ }
4540
+ }
4541
+ const key = path.fullPath;
4542
+ const ttlToUse = TTL$3;
4543
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$3, "EinsteinLLM", VERSION$5, RepresentationType$3, equals$5);
4544
+ return createLink(key);
4545
+ };
4546
+ function getTypeCacheKeys$3(rootKeySet, luvio, input, fullPathFactory) {
4547
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
4548
+ const rootKey = fullPathFactory();
4549
+ rootKeySet.set(rootKey, {
4550
+ namespace: keyPrefix,
4551
+ representationName: RepresentationType$3,
4552
+ mergeable: false
4553
+ });
4554
+ }
4555
+
4556
+ function select$d(luvio, params) {
4557
+ return select$e();
4558
+ }
4559
+ function keyBuilder$d(luvio, params) {
4560
+ return keyPrefix + '::PromptTemplateDataProviderInstanceConfigCollectionRepresentation:(' + 'groupNames:' + params.queryParams.groupNames + ',' + 'targets:' + params.queryParams.targets + ',' + 'templateType:' + params.urlParams.templateType + ')';
4561
+ }
4562
+ function getResponseCacheKeys$8(storeKeyMap, luvio, resourceParams, response) {
4563
+ getTypeCacheKeys$3(storeKeyMap, luvio, response, () => keyBuilder$d(luvio, resourceParams));
4564
+ }
4565
+ function ingestSuccess$8(luvio, resourceParams, response, snapshotRefresh) {
4566
+ const { body } = response;
4567
+ const key = keyBuilder$d(luvio, resourceParams);
4568
+ luvio.storeIngest(key, ingest$3, body);
4569
+ const snapshot = luvio.storeLookup({
4570
+ recordId: key,
4571
+ node: select$d(),
4572
+ variables: {},
4573
+ }, snapshotRefresh);
4574
+ if (process.env.NODE_ENV !== 'production') {
4575
+ if (snapshot.state !== 'Fulfilled') {
4576
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
4577
+ }
4578
+ }
4579
+ deepFreeze(snapshot.data);
4580
+ return snapshot;
4581
+ }
4582
+ function ingestError$6(luvio, params, error, snapshotRefresh) {
4583
+ const key = keyBuilder$d(luvio, params);
4584
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
4585
+ const storeMetadataParams = {
4586
+ ttl: TTL$3,
4587
+ namespace: keyPrefix,
4588
+ version: VERSION$5,
4589
+ representationName: RepresentationType$3
4590
+ };
4591
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
4592
+ return errorSnapshot;
4593
+ }
4594
+ function createResourceRequest$8(config) {
4595
+ const headers = {};
4596
+ return {
4597
+ baseUri: '/services/data/v65.0',
4598
+ basePath: '/einstein/prompt-templates/data-providers/' + config.urlParams.templateType + '',
4599
+ method: 'get',
4600
+ body: null,
4601
+ urlParams: config.urlParams,
4602
+ queryParams: config.queryParams,
4603
+ headers,
4604
+ priority: 'normal',
4605
+ };
4606
+ }
4607
+
4608
+ const adapterName$8 = 'getDataProviders';
4609
+ const getDataProviders_ConfigPropertyMetadata = [
4610
+ generateParamConfigMetadata('templateType', true, 0 /* UrlParameter */, 0 /* String */),
4611
+ generateParamConfigMetadata('groupNames', false, 1 /* QueryParameter */, 0 /* String */, true),
4612
+ generateParamConfigMetadata('targets', false, 1 /* QueryParameter */, 0 /* String */, true),
4613
+ ];
4614
+ const getDataProviders_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$8, getDataProviders_ConfigPropertyMetadata);
4615
+ const createResourceParams$8 = /*#__PURE__*/ createResourceParams$h(getDataProviders_ConfigPropertyMetadata);
4616
+ function keyBuilder$c(luvio, config) {
4617
+ const resourceParams = createResourceParams$8(config);
4618
+ return keyBuilder$d(luvio, resourceParams);
4619
+ }
4620
+ function typeCheckConfig$8(untrustedConfig) {
4621
+ const config = {};
4622
+ typeCheckConfig$h(untrustedConfig, config, getDataProviders_ConfigPropertyMetadata);
4623
+ return config;
4624
+ }
4625
+ function validateAdapterConfig$8(untrustedConfig, configPropertyNames) {
4626
+ if (!untrustedIsObject(untrustedConfig)) {
4627
+ return null;
4628
+ }
4629
+ if (process.env.NODE_ENV !== 'production') {
4630
+ validateConfig(untrustedConfig, configPropertyNames);
4631
+ }
4632
+ const config = typeCheckConfig$8(untrustedConfig);
4633
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
4634
+ return null;
4635
+ }
4636
+ return config;
4637
+ }
4638
+ function adapterFragment$6(luvio, config) {
4639
+ createResourceParams$8(config);
4640
+ return select$d();
4641
+ }
4642
+ function onFetchResponseSuccess$6(luvio, config, resourceParams, response) {
4643
+ const snapshot = ingestSuccess$8(luvio, resourceParams, response, {
4644
+ config,
4645
+ resolve: () => buildNetworkSnapshot$8(luvio, config, snapshotRefreshOptions)
4646
+ });
4647
+ return luvio.storeBroadcast().then(() => snapshot);
4648
+ }
4649
+ function onFetchResponseError$6(luvio, config, resourceParams, response) {
4650
+ const snapshot = ingestError$6(luvio, resourceParams, response, {
4651
+ config,
4652
+ resolve: () => buildNetworkSnapshot$8(luvio, config, snapshotRefreshOptions)
4653
+ });
4654
+ return luvio.storeBroadcast().then(() => snapshot);
4655
+ }
4656
+ function buildNetworkSnapshot$8(luvio, config, options) {
4657
+ const resourceParams = createResourceParams$8(config);
4658
+ const request = createResourceRequest$8(resourceParams);
4659
+ return luvio.dispatchResourceRequest(request, options)
4660
+ .then((response) => {
4661
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$6(luvio, config, resourceParams, response), () => {
4662
+ const cache = new StoreKeyMap();
4663
+ getResponseCacheKeys$8(cache, luvio, resourceParams, response.body);
4664
+ return cache;
4665
+ });
4666
+ }, (response) => {
4667
+ return luvio.handleErrorResponse(() => onFetchResponseError$6(luvio, config, resourceParams, response));
4668
+ });
4669
+ }
4670
+ function buildNetworkSnapshotCachePolicy$6(context, coercedAdapterRequestContext) {
4671
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$8, undefined, false);
4672
+ }
4673
+ function buildCachedSnapshotCachePolicy$6(context, storeLookup) {
4674
+ const { luvio, config } = context;
4675
+ const selector = {
4676
+ recordId: keyBuilder$c(luvio, config),
4677
+ node: adapterFragment$6(luvio, config),
4678
+ variables: {},
4679
+ };
4680
+ const cacheSnapshot = storeLookup(selector, {
4681
+ config,
4682
+ resolve: () => buildNetworkSnapshot$8(luvio, config, snapshotRefreshOptions)
4683
+ });
4684
+ return cacheSnapshot;
4685
+ }
4686
+ const getDataProvidersAdapterFactory = (luvio) => function EinsteinLLM__getDataProviders(untrustedConfig, requestContext) {
4687
+ const config = validateAdapterConfig$8(untrustedConfig, getDataProviders_ConfigPropertyNames);
4688
+ // Invalid or incomplete config
4689
+ if (config === null) {
4690
+ return null;
4691
+ }
4692
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
4693
+ buildCachedSnapshotCachePolicy$6, buildNetworkSnapshotCachePolicy$6);
4694
+ };
4695
+
4696
+ function select$c(luvio, params) {
4697
+ return select$e();
4698
+ }
4699
+ function keyBuilder$b(luvio, params) {
4700
+ 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 + ')';
4701
+ }
4702
+ function getResponseCacheKeys$7(storeKeyMap, luvio, resourceParams, response) {
4703
+ getTypeCacheKeys$3(storeKeyMap, luvio, response, () => keyBuilder$b(luvio, resourceParams));
4704
+ }
4705
+ function ingestSuccess$7(luvio, resourceParams, response, snapshotRefresh) {
4706
+ const { body } = response;
4707
+ const key = keyBuilder$b(luvio, resourceParams);
4708
+ luvio.storeIngest(key, ingest$3, body);
4709
+ const snapshot = luvio.storeLookup({
4710
+ recordId: key,
4711
+ node: select$c(),
4712
+ variables: {},
4713
+ }, snapshotRefresh);
4714
+ if (process.env.NODE_ENV !== 'production') {
4715
+ if (snapshot.state !== 'Fulfilled') {
4716
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
4717
+ }
4718
+ }
4719
+ deepFreeze(snapshot.data);
4720
+ return snapshot;
4721
+ }
4722
+ function ingestError$5(luvio, params, error, snapshotRefresh) {
4723
+ const key = keyBuilder$b(luvio, params);
4724
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
4725
+ const storeMetadataParams = {
4726
+ ttl: TTL$3,
4727
+ namespace: keyPrefix,
4728
+ version: VERSION$5,
4729
+ representationName: RepresentationType$3
4730
+ };
4731
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
4732
+ return errorSnapshot;
4733
+ }
4734
+ function createResourceRequest$7(config) {
4735
+ const headers = {};
4736
+ return {
4737
+ baseUri: '/services/data/v65.0',
4738
+ basePath: '/einstein/prompt-templates/data-providers/mapped',
4739
+ method: 'post',
4740
+ body: config.body,
4741
+ urlParams: {},
4742
+ queryParams: {},
4743
+ headers,
4744
+ priority: 'normal',
4745
+ };
4746
+ }
4747
+
4748
+ const adapterName$7 = 'getInputMappedDataProviders';
4749
+ const getInputMappedDataProviders_ConfigPropertyMetadata = [
4750
+ generateParamConfigMetadata('groupName', false, 2 /* Body */, 0 /* String */),
4751
+ generateParamConfigMetadata('target', false, 2 /* Body */, 0 /* String */),
4752
+ generateParamConfigMetadata('templateInputs', true, 2 /* Body */, 4 /* Unsupported */, true),
4753
+ generateParamConfigMetadata('templateTypeName', true, 2 /* Body */, 0 /* String */),
4754
+ ];
4755
+ const getInputMappedDataProviders_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$7, getInputMappedDataProviders_ConfigPropertyMetadata);
4756
+ const createResourceParams$7 = /*#__PURE__*/ createResourceParams$h(getInputMappedDataProviders_ConfigPropertyMetadata);
4757
+ function keyBuilder$a(luvio, config) {
4758
+ const resourceParams = createResourceParams$7(config);
4759
+ return keyBuilder$b(luvio, resourceParams);
4760
+ }
4761
+ function typeCheckConfig$7(untrustedConfig) {
4762
+ const config = {};
4763
+ typeCheckConfig$h(untrustedConfig, config, getInputMappedDataProviders_ConfigPropertyMetadata);
4764
+ const untrustedConfig_templateInputs = untrustedConfig.templateInputs;
4765
+ if (ArrayIsArray$1(untrustedConfig_templateInputs)) {
4766
+ const untrustedConfig_templateInputs_array = [];
4767
+ for (let i = 0, arrayLength = untrustedConfig_templateInputs.length; i < arrayLength; i++) {
4768
+ const untrustedConfig_templateInputs_item = untrustedConfig_templateInputs[i];
4769
+ untrustedConfig_templateInputs_array.push(untrustedConfig_templateInputs_item);
4770
+ }
4771
+ config.templateInputs = untrustedConfig_templateInputs_array;
4772
+ }
4773
+ return config;
4774
+ }
4775
+ function validateAdapterConfig$7(untrustedConfig, configPropertyNames) {
4776
+ if (!untrustedIsObject(untrustedConfig)) {
4777
+ return null;
4778
+ }
4779
+ if (process.env.NODE_ENV !== 'production') {
4780
+ validateConfig(untrustedConfig, configPropertyNames);
4781
+ }
4782
+ const config = typeCheckConfig$7(untrustedConfig);
4783
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
4784
+ return null;
4785
+ }
4786
+ return config;
4787
+ }
4788
+ function adapterFragment$5(luvio, config) {
4789
+ createResourceParams$7(config);
4790
+ return select$c();
4791
+ }
4792
+ function onFetchResponseSuccess$5(luvio, config, resourceParams, response) {
4793
+ const snapshot = ingestSuccess$7(luvio, resourceParams, response, {
4794
+ config,
4795
+ resolve: () => buildNetworkSnapshot$7(luvio, config, snapshotRefreshOptions)
4796
+ });
4797
+ return luvio.storeBroadcast().then(() => snapshot);
4798
+ }
4799
+ function onFetchResponseError$5(luvio, config, resourceParams, response) {
4800
+ const snapshot = ingestError$5(luvio, resourceParams, response, {
4801
+ config,
4802
+ resolve: () => buildNetworkSnapshot$7(luvio, config, snapshotRefreshOptions)
4803
+ });
4804
+ return luvio.storeBroadcast().then(() => snapshot);
4805
+ }
4806
+ function buildNetworkSnapshot$7(luvio, config, options) {
4807
+ const resourceParams = createResourceParams$7(config);
4808
+ const request = createResourceRequest$7(resourceParams);
4809
+ return luvio.dispatchResourceRequest(request, options)
4810
+ .then((response) => {
4811
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$5(luvio, config, resourceParams, response), () => {
4812
+ const cache = new StoreKeyMap();
4813
+ getResponseCacheKeys$7(cache, luvio, resourceParams, response.body);
4814
+ return cache;
4815
+ });
4816
+ }, (response) => {
4817
+ return luvio.handleErrorResponse(() => onFetchResponseError$5(luvio, config, resourceParams, response));
4818
+ });
4819
+ }
4820
+ function buildNetworkSnapshotCachePolicy$5(context, coercedAdapterRequestContext) {
4821
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$7, 'get', false);
4822
+ }
4823
+ function buildCachedSnapshotCachePolicy$5(context, storeLookup) {
4824
+ const { luvio, config } = context;
4825
+ const selector = {
4826
+ recordId: keyBuilder$a(luvio, config),
4827
+ node: adapterFragment$5(luvio, config),
4828
+ variables: {},
4829
+ };
4830
+ const cacheSnapshot = storeLookup(selector, {
4831
+ config,
4832
+ resolve: () => buildNetworkSnapshot$7(luvio, config, snapshotRefreshOptions)
4833
+ });
4834
+ return cacheSnapshot;
4835
+ }
4836
+ const getInputMappedDataProvidersAdapterFactory = (luvio) => function EinsteinLLM__getInputMappedDataProviders(untrustedConfig, requestContext) {
4837
+ const config = validateAdapterConfig$7(untrustedConfig, getInputMappedDataProviders_ConfigPropertyNames);
4838
+ // Invalid or incomplete config
4839
+ if (config === null) {
4840
+ return null;
4841
+ }
4842
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
4843
+ buildCachedSnapshotCachePolicy$5, buildNetworkSnapshotCachePolicy$5);
4844
+ };
4845
+
4846
+ const VERSION$4 = "b513bbac1672327d8eaaf120660e94b5";
4847
+ function validate$5(obj, path = 'EinsteinPromptTemplateSupportedLanguageErrorRepresentation') {
4848
+ const v_error = (() => {
4849
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
4850
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
4851
+ }
4852
+ const obj_errorMessage = obj.errorMessage;
4853
+ const path_errorMessage = path + '.errorMessage';
4854
+ if (typeof obj_errorMessage !== 'string') {
4855
+ return new TypeError('Expected "string" but received "' + typeof obj_errorMessage + '" (at "' + path_errorMessage + '")');
4856
+ }
4857
+ const obj_messageCode = obj.messageCode;
4858
+ const path_messageCode = path + '.messageCode';
4859
+ if (typeof obj_messageCode !== 'string') {
4860
+ return new TypeError('Expected "string" but received "' + typeof obj_messageCode + '" (at "' + path_messageCode + '")');
4861
+ }
4862
+ })();
4863
+ return v_error === undefined ? null : v_error;
4864
+ }
4865
+ const select$b = function EinsteinPromptTemplateSupportedLanguageErrorRepresentationSelect() {
4866
+ return {
4867
+ kind: 'Fragment',
4868
+ version: VERSION$4,
4869
+ private: [],
4870
+ selections: [
4871
+ {
4872
+ name: 'errorMessage',
4873
+ kind: 'Scalar'
4874
+ },
4875
+ {
4876
+ name: 'messageCode',
4877
+ kind: 'Scalar'
4878
+ }
4879
+ ]
4880
+ };
4881
+ };
4882
+ function equals$4(existing, incoming) {
4883
+ const existing_errorMessage = existing.errorMessage;
4884
+ const incoming_errorMessage = incoming.errorMessage;
4885
+ if (!(existing_errorMessage === incoming_errorMessage)) {
4886
+ return false;
4887
+ }
4888
+ const existing_messageCode = existing.messageCode;
4889
+ const incoming_messageCode = incoming.messageCode;
4890
+ if (!(existing_messageCode === incoming_messageCode)) {
4891
+ return false;
4892
+ }
4893
+ return true;
4894
+ }
4895
+
4896
+ const VERSION$3 = "65a17d345c28eeca91872a73d8ffe9fd";
4897
+ function validate$4(obj, path = 'EinsteinPromptTemplateSupportedLanguageRepresentation') {
4898
+ const v_error = (() => {
4899
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
4900
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
4901
+ }
4902
+ const obj_languageCode = obj.languageCode;
4903
+ const path_languageCode = path + '.languageCode';
4904
+ if (typeof obj_languageCode !== 'string') {
4905
+ return new TypeError('Expected "string" but received "' + typeof obj_languageCode + '" (at "' + path_languageCode + '")');
4906
+ }
4907
+ const obj_languageDisplayName = obj.languageDisplayName;
4908
+ const path_languageDisplayName = path + '.languageDisplayName';
4909
+ if (typeof obj_languageDisplayName !== 'string') {
4910
+ return new TypeError('Expected "string" but received "' + typeof obj_languageDisplayName + '" (at "' + path_languageDisplayName + '")');
4911
+ }
4912
+ })();
4913
+ return v_error === undefined ? null : v_error;
4914
+ }
4915
+ const select$a = function EinsteinPromptTemplateSupportedLanguageRepresentationSelect() {
4916
+ return {
4917
+ kind: 'Fragment',
4918
+ version: VERSION$3,
4919
+ private: [],
4920
+ selections: [
4921
+ {
4922
+ name: 'languageCode',
4923
+ kind: 'Scalar'
4924
+ },
4925
+ {
4926
+ name: 'languageDisplayName',
4927
+ kind: 'Scalar'
4928
+ }
4929
+ ]
4930
+ };
4931
+ };
4932
+ function equals$3(existing, incoming) {
4933
+ const existing_languageCode = existing.languageCode;
4934
+ const incoming_languageCode = incoming.languageCode;
4935
+ if (!(existing_languageCode === incoming_languageCode)) {
4936
+ return false;
4937
+ }
4938
+ const existing_languageDisplayName = existing.languageDisplayName;
4939
+ const incoming_languageDisplayName = incoming.languageDisplayName;
4940
+ if (!(existing_languageDisplayName === incoming_languageDisplayName)) {
4941
+ return false;
4942
+ }
4943
+ return true;
4944
+ }
4945
+
4946
+ const TTL$2 = 100;
4947
+ const VERSION$2 = "c635f260bce9a11f7c3bf31d60f42b53";
4948
+ function validate$3(obj, path = 'EinsteinPromptTemplateVersionOutputLanguagesRepresentation') {
4949
+ const v_error = (() => {
4950
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
4951
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
4952
+ }
4953
+ const obj_errors = obj.errors;
4954
+ const path_errors = path + '.errors';
4955
+ if (!ArrayIsArray(obj_errors)) {
4956
+ return new TypeError('Expected "array" but received "' + typeof obj_errors + '" (at "' + path_errors + '")');
4957
+ }
4958
+ for (let i = 0; i < obj_errors.length; i++) {
4959
+ const obj_errors_item = obj_errors[i];
4960
+ const path_errors_item = path_errors + '[' + i + ']';
4961
+ const referencepath_errors_itemValidationError = validate$5(obj_errors_item, path_errors_item);
4962
+ if (referencepath_errors_itemValidationError !== null) {
4963
+ let message = 'Object doesn\'t match EinsteinPromptTemplateSupportedLanguageErrorRepresentation (at "' + path_errors_item + '")\n';
4964
+ message += referencepath_errors_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
4965
+ return new TypeError(message);
4966
+ }
4967
+ }
4968
+ const obj_isSuccess = obj.isSuccess;
4969
+ const path_isSuccess = path + '.isSuccess';
4970
+ if (typeof obj_isSuccess !== 'boolean') {
4971
+ return new TypeError('Expected "boolean" but received "' + typeof obj_isSuccess + '" (at "' + path_isSuccess + '")');
4972
+ }
4973
+ const obj_promptTemplateDevName = obj.promptTemplateDevName;
4974
+ const path_promptTemplateDevName = path + '.promptTemplateDevName';
4975
+ if (typeof obj_promptTemplateDevName !== 'string') {
4976
+ return new TypeError('Expected "string" but received "' + typeof obj_promptTemplateDevName + '" (at "' + path_promptTemplateDevName + '")');
4977
+ }
4978
+ const obj_supportedLanguages = obj.supportedLanguages;
4979
+ const path_supportedLanguages = path + '.supportedLanguages';
4980
+ if (!ArrayIsArray(obj_supportedLanguages)) {
4981
+ return new TypeError('Expected "array" but received "' + typeof obj_supportedLanguages + '" (at "' + path_supportedLanguages + '")');
4982
+ }
4983
+ for (let i = 0; i < obj_supportedLanguages.length; i++) {
4984
+ const obj_supportedLanguages_item = obj_supportedLanguages[i];
4985
+ const path_supportedLanguages_item = path_supportedLanguages + '[' + i + ']';
4986
+ const referencepath_supportedLanguages_itemValidationError = validate$4(obj_supportedLanguages_item, path_supportedLanguages_item);
4987
+ if (referencepath_supportedLanguages_itemValidationError !== null) {
4988
+ let message = 'Object doesn\'t match EinsteinPromptTemplateSupportedLanguageRepresentation (at "' + path_supportedLanguages_item + '")\n';
4989
+ message += referencepath_supportedLanguages_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
4990
+ return new TypeError(message);
4991
+ }
4992
+ }
4993
+ const obj_versionId = obj.versionId;
3624
4994
  const path_versionId = path + '.versionId';
3625
4995
  if (typeof obj_versionId !== 'string') {
3626
4996
  return new TypeError('Expected "string" but received "' + typeof obj_versionId + '" (at "' + path_versionId + '")');
@@ -3632,9 +5002,9 @@ const RepresentationType$2 = 'EinsteinPromptTemplateVersionOutputLanguagesRepres
3632
5002
  function normalize$2(input, existing, path, luvio, store, timestamp) {
3633
5003
  return input;
3634
5004
  }
3635
- const select$6 = function EinsteinPromptTemplateVersionOutputLanguagesRepresentationSelect() {
3636
- const { selections: EinsteinPromptTemplateSupportedLanguageErrorRepresentation__selections, opaque: EinsteinPromptTemplateSupportedLanguageErrorRepresentation__opaque, } = select$8();
3637
- const { selections: EinsteinPromptTemplateSupportedLanguageRepresentation__selections, opaque: EinsteinPromptTemplateSupportedLanguageRepresentation__opaque, } = select$7();
5005
+ const select$9 = function EinsteinPromptTemplateVersionOutputLanguagesRepresentationSelect() {
5006
+ const { selections: EinsteinPromptTemplateSupportedLanguageErrorRepresentation__selections, opaque: EinsteinPromptTemplateSupportedLanguageErrorRepresentation__opaque, } = select$b();
5007
+ const { selections: EinsteinPromptTemplateSupportedLanguageRepresentation__selections, opaque: EinsteinPromptTemplateSupportedLanguageRepresentation__opaque, } = select$a();
3638
5008
  return {
3639
5009
  kind: 'Fragment',
3640
5010
  version: VERSION$2,
@@ -3727,22 +5097,22 @@ function getTypeCacheKeys$2(rootKeySet, luvio, input, fullPathFactory) {
3727
5097
  });
3728
5098
  }
3729
5099
 
3730
- function select$5(luvio, params) {
3731
- return select$6();
5100
+ function select$8(luvio, params) {
5101
+ return select$9();
3732
5102
  }
3733
- function keyBuilder$5(luvio, params) {
5103
+ function keyBuilder$9(luvio, params) {
3734
5104
  return keyPrefix + '::EinsteinPromptTemplateVersionOutputLanguagesRepresentation:(' + 'useStandardVersion:' + params.queryParams.useStandardVersion + ',' + 'versionId:' + params.queryParams.versionId + ',' + 'promptTemplateDevName:' + params.urlParams.promptTemplateDevName + ')';
3735
5105
  }
3736
- function getResponseCacheKeys$3(storeKeyMap, luvio, resourceParams, response) {
3737
- getTypeCacheKeys$2(storeKeyMap, luvio, response, () => keyBuilder$5(luvio, resourceParams));
5106
+ function getResponseCacheKeys$6(storeKeyMap, luvio, resourceParams, response) {
5107
+ getTypeCacheKeys$2(storeKeyMap, luvio, response, () => keyBuilder$9(luvio, resourceParams));
3738
5108
  }
3739
- function ingestSuccess$3(luvio, resourceParams, response, snapshotRefresh) {
5109
+ function ingestSuccess$6(luvio, resourceParams, response, snapshotRefresh) {
3740
5110
  const { body } = response;
3741
- const key = keyBuilder$5(luvio, resourceParams);
5111
+ const key = keyBuilder$9(luvio, resourceParams);
3742
5112
  luvio.storeIngest(key, ingest$2, body);
3743
5113
  const snapshot = luvio.storeLookup({
3744
5114
  recordId: key,
3745
- node: select$5(),
5115
+ node: select$8(),
3746
5116
  variables: {},
3747
5117
  }, snapshotRefresh);
3748
5118
  if (process.env.NODE_ENV !== 'production') {
@@ -3753,8 +5123,8 @@ function ingestSuccess$3(luvio, resourceParams, response, snapshotRefresh) {
3753
5123
  deepFreeze(snapshot.data);
3754
5124
  return snapshot;
3755
5125
  }
3756
- function ingestError$2(luvio, params, error, snapshotRefresh) {
3757
- const key = keyBuilder$5(luvio, params);
5126
+ function ingestError$4(luvio, params, error, snapshotRefresh) {
5127
+ const key = keyBuilder$9(luvio, params);
3758
5128
  const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
3759
5129
  const storeMetadataParams = {
3760
5130
  ttl: TTL$2,
@@ -3765,7 +5135,7 @@ function ingestError$2(luvio, params, error, snapshotRefresh) {
3765
5135
  luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
3766
5136
  return errorSnapshot;
3767
5137
  }
3768
- function createResourceRequest$3(config) {
5138
+ function createResourceRequest$6(config) {
3769
5139
  const headers = {};
3770
5140
  return {
3771
5141
  baseUri: '/services/data/v65.0',
@@ -3779,92 +5149,92 @@ function createResourceRequest$3(config) {
3779
5149
  };
3780
5150
  }
3781
5151
 
3782
- const adapterName$3 = 'getOutputLanguages';
5152
+ const adapterName$6 = 'getOutputLanguages';
3783
5153
  const getOutputLanguages_ConfigPropertyMetadata = [
3784
5154
  generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
3785
5155
  generateParamConfigMetadata('useStandardVersion', false, 1 /* QueryParameter */, 1 /* Boolean */),
3786
5156
  generateParamConfigMetadata('versionId', false, 1 /* QueryParameter */, 0 /* String */),
3787
5157
  ];
3788
- const getOutputLanguages_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$3, getOutputLanguages_ConfigPropertyMetadata);
3789
- const createResourceParams$3 = /*#__PURE__*/ createResourceParams$a(getOutputLanguages_ConfigPropertyMetadata);
3790
- function keyBuilder$4(luvio, config) {
3791
- const resourceParams = createResourceParams$3(config);
3792
- return keyBuilder$5(luvio, resourceParams);
5158
+ const getOutputLanguages_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$6, getOutputLanguages_ConfigPropertyMetadata);
5159
+ const createResourceParams$6 = /*#__PURE__*/ createResourceParams$h(getOutputLanguages_ConfigPropertyMetadata);
5160
+ function keyBuilder$8(luvio, config) {
5161
+ const resourceParams = createResourceParams$6(config);
5162
+ return keyBuilder$9(luvio, resourceParams);
3793
5163
  }
3794
- function typeCheckConfig$3(untrustedConfig) {
5164
+ function typeCheckConfig$6(untrustedConfig) {
3795
5165
  const config = {};
3796
- typeCheckConfig$a(untrustedConfig, config, getOutputLanguages_ConfigPropertyMetadata);
5166
+ typeCheckConfig$h(untrustedConfig, config, getOutputLanguages_ConfigPropertyMetadata);
3797
5167
  return config;
3798
5168
  }
3799
- function validateAdapterConfig$3(untrustedConfig, configPropertyNames) {
5169
+ function validateAdapterConfig$6(untrustedConfig, configPropertyNames) {
3800
5170
  if (!untrustedIsObject(untrustedConfig)) {
3801
5171
  return null;
3802
5172
  }
3803
5173
  if (process.env.NODE_ENV !== 'production') {
3804
5174
  validateConfig(untrustedConfig, configPropertyNames);
3805
5175
  }
3806
- const config = typeCheckConfig$3(untrustedConfig);
5176
+ const config = typeCheckConfig$6(untrustedConfig);
3807
5177
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
3808
5178
  return null;
3809
5179
  }
3810
5180
  return config;
3811
5181
  }
3812
- function adapterFragment$2(luvio, config) {
3813
- createResourceParams$3(config);
3814
- return select$5();
5182
+ function adapterFragment$4(luvio, config) {
5183
+ createResourceParams$6(config);
5184
+ return select$8();
3815
5185
  }
3816
- function onFetchResponseSuccess$2(luvio, config, resourceParams, response) {
3817
- const snapshot = ingestSuccess$3(luvio, resourceParams, response, {
5186
+ function onFetchResponseSuccess$4(luvio, config, resourceParams, response) {
5187
+ const snapshot = ingestSuccess$6(luvio, resourceParams, response, {
3818
5188
  config,
3819
- resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
5189
+ resolve: () => buildNetworkSnapshot$6(luvio, config, snapshotRefreshOptions)
3820
5190
  });
3821
5191
  return luvio.storeBroadcast().then(() => snapshot);
3822
5192
  }
3823
- function onFetchResponseError$2(luvio, config, resourceParams, response) {
3824
- const snapshot = ingestError$2(luvio, resourceParams, response, {
5193
+ function onFetchResponseError$4(luvio, config, resourceParams, response) {
5194
+ const snapshot = ingestError$4(luvio, resourceParams, response, {
3825
5195
  config,
3826
- resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
5196
+ resolve: () => buildNetworkSnapshot$6(luvio, config, snapshotRefreshOptions)
3827
5197
  });
3828
5198
  return luvio.storeBroadcast().then(() => snapshot);
3829
5199
  }
3830
- function buildNetworkSnapshot$3(luvio, config, options) {
3831
- const resourceParams = createResourceParams$3(config);
3832
- const request = createResourceRequest$3(resourceParams);
5200
+ function buildNetworkSnapshot$6(luvio, config, options) {
5201
+ const resourceParams = createResourceParams$6(config);
5202
+ const request = createResourceRequest$6(resourceParams);
3833
5203
  return luvio.dispatchResourceRequest(request, options)
3834
5204
  .then((response) => {
3835
- return luvio.handleSuccessResponse(() => onFetchResponseSuccess$2(luvio, config, resourceParams, response), () => {
5205
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$4(luvio, config, resourceParams, response), () => {
3836
5206
  const cache = new StoreKeyMap();
3837
- getResponseCacheKeys$3(cache, luvio, resourceParams, response.body);
5207
+ getResponseCacheKeys$6(cache, luvio, resourceParams, response.body);
3838
5208
  return cache;
3839
5209
  });
3840
5210
  }, (response) => {
3841
- return luvio.handleErrorResponse(() => onFetchResponseError$2(luvio, config, resourceParams, response));
5211
+ return luvio.handleErrorResponse(() => onFetchResponseError$4(luvio, config, resourceParams, response));
3842
5212
  });
3843
5213
  }
3844
- function buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext) {
3845
- return buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext, buildNetworkSnapshot$3, undefined, false);
5214
+ function buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext) {
5215
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$6, undefined, false);
3846
5216
  }
3847
- function buildCachedSnapshotCachePolicy$2(context, storeLookup) {
5217
+ function buildCachedSnapshotCachePolicy$4(context, storeLookup) {
3848
5218
  const { luvio, config } = context;
3849
5219
  const selector = {
3850
- recordId: keyBuilder$4(luvio, config),
3851
- node: adapterFragment$2(luvio, config),
5220
+ recordId: keyBuilder$8(luvio, config),
5221
+ node: adapterFragment$4(luvio, config),
3852
5222
  variables: {},
3853
5223
  };
3854
5224
  const cacheSnapshot = storeLookup(selector, {
3855
5225
  config,
3856
- resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
5226
+ resolve: () => buildNetworkSnapshot$6(luvio, config, snapshotRefreshOptions)
3857
5227
  });
3858
5228
  return cacheSnapshot;
3859
5229
  }
3860
5230
  const getOutputLanguagesAdapterFactory = (luvio) => function EinsteinLLM__getOutputLanguages(untrustedConfig, requestContext) {
3861
- const config = validateAdapterConfig$3(untrustedConfig, getOutputLanguages_ConfigPropertyNames);
5231
+ const config = validateAdapterConfig$6(untrustedConfig, getOutputLanguages_ConfigPropertyNames);
3862
5232
  // Invalid or incomplete config
3863
5233
  if (config === null) {
3864
5234
  return null;
3865
5235
  }
3866
5236
  return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
3867
- buildCachedSnapshotCachePolicy$2, buildNetworkSnapshotCachePolicy$2);
5237
+ buildCachedSnapshotCachePolicy$4, buildNetworkSnapshotCachePolicy$4);
3868
5238
  };
3869
5239
 
3870
5240
  function validate$2(obj, path = 'EinsteinPromptRecordFieldRepresentation') {
@@ -4000,58 +5370,338 @@ const RepresentationType$1 = 'EinsteinPromptRecordRepresentation';
4000
5370
  function normalize$1(input, existing, path, luvio, store, timestamp) {
4001
5371
  return input;
4002
5372
  }
4003
- const select$4 = function EinsteinPromptRecordRepresentationSelect() {
4004
- return {
4005
- kind: 'Fragment',
4006
- version: VERSION$1,
4007
- private: [],
4008
- opaque: true
4009
- };
4010
- };
4011
- function equals$1(existing, incoming) {
4012
- if (JSONStringify(incoming) !== JSONStringify(existing)) {
4013
- return false;
5373
+ const select$7 = function EinsteinPromptRecordRepresentationSelect() {
5374
+ return {
5375
+ kind: 'Fragment',
5376
+ version: VERSION$1,
5377
+ private: [],
5378
+ opaque: true
5379
+ };
5380
+ };
5381
+ function equals$1(existing, incoming) {
5382
+ if (JSONStringify(incoming) !== JSONStringify(existing)) {
5383
+ return false;
5384
+ }
5385
+ return true;
5386
+ }
5387
+ const ingest$1 = function EinsteinPromptRecordRepresentationIngest(input, path, luvio, store, timestamp) {
5388
+ if (process.env.NODE_ENV !== 'production') {
5389
+ const validateError = validate$1(input);
5390
+ if (validateError !== null) {
5391
+ throw validateError;
5392
+ }
5393
+ }
5394
+ const key = path.fullPath;
5395
+ const ttlToUse = TTL$1;
5396
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$1, "EinsteinLLM", VERSION$1, RepresentationType$1, equals$1);
5397
+ return createLink(key);
5398
+ };
5399
+ function getTypeCacheKeys$1(rootKeySet, luvio, input, fullPathFactory) {
5400
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
5401
+ const rootKey = fullPathFactory();
5402
+ rootKeySet.set(rootKey, {
5403
+ namespace: keyPrefix,
5404
+ representationName: RepresentationType$1,
5405
+ mergeable: false
5406
+ });
5407
+ }
5408
+
5409
+ function select$6(luvio, params) {
5410
+ return select$7();
5411
+ }
5412
+ function keyBuilder$7(luvio, params) {
5413
+ return keyPrefix + '::EinsteinPromptRecordRepresentation:(' + 'versionId:' + params.queryParams.versionId + ',' + 'promptTemplateDevName:' + params.urlParams.promptTemplateDevName + ')';
5414
+ }
5415
+ function getResponseCacheKeys$5(storeKeyMap, luvio, resourceParams, response) {
5416
+ getTypeCacheKeys$1(storeKeyMap, luvio, response, () => keyBuilder$7(luvio, resourceParams));
5417
+ }
5418
+ function ingestSuccess$5(luvio, resourceParams, response, snapshotRefresh) {
5419
+ const { body } = response;
5420
+ const key = keyBuilder$7(luvio, resourceParams);
5421
+ luvio.storeIngest(key, ingest$1, body);
5422
+ const snapshot = luvio.storeLookup({
5423
+ recordId: key,
5424
+ node: select$6(),
5425
+ variables: {},
5426
+ }, snapshotRefresh);
5427
+ if (process.env.NODE_ENV !== 'production') {
5428
+ if (snapshot.state !== 'Fulfilled') {
5429
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
5430
+ }
5431
+ }
5432
+ deepFreeze(snapshot.data);
5433
+ return snapshot;
5434
+ }
5435
+ function ingestError$3(luvio, params, error, snapshotRefresh) {
5436
+ const key = keyBuilder$7(luvio, params);
5437
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
5438
+ const storeMetadataParams = {
5439
+ ttl: TTL$1,
5440
+ namespace: keyPrefix,
5441
+ version: VERSION$1,
5442
+ representationName: RepresentationType$1
5443
+ };
5444
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
5445
+ return errorSnapshot;
5446
+ }
5447
+ function createResourceRequest$5(config) {
5448
+ const headers = {};
5449
+ return {
5450
+ baseUri: '/services/data/v65.0',
5451
+ basePath: '/einstein/prompt-templates/' + config.urlParams.promptTemplateDevName + '',
5452
+ method: 'get',
5453
+ body: null,
5454
+ urlParams: config.urlParams,
5455
+ queryParams: config.queryParams,
5456
+ headers,
5457
+ priority: 'normal',
5458
+ };
5459
+ }
5460
+
5461
+ const adapterName$5 = 'getPromptTemplate';
5462
+ const getPromptTemplate_ConfigPropertyMetadata = [
5463
+ generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
5464
+ generateParamConfigMetadata('versionId', false, 1 /* QueryParameter */, 0 /* String */),
5465
+ ];
5466
+ const getPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$5, getPromptTemplate_ConfigPropertyMetadata);
5467
+ const createResourceParams$5 = /*#__PURE__*/ createResourceParams$h(getPromptTemplate_ConfigPropertyMetadata);
5468
+ function keyBuilder$6(luvio, config) {
5469
+ const resourceParams = createResourceParams$5(config);
5470
+ return keyBuilder$7(luvio, resourceParams);
5471
+ }
5472
+ function typeCheckConfig$5(untrustedConfig) {
5473
+ const config = {};
5474
+ typeCheckConfig$h(untrustedConfig, config, getPromptTemplate_ConfigPropertyMetadata);
5475
+ return config;
5476
+ }
5477
+ function validateAdapterConfig$5(untrustedConfig, configPropertyNames) {
5478
+ if (!untrustedIsObject(untrustedConfig)) {
5479
+ return null;
5480
+ }
5481
+ if (process.env.NODE_ENV !== 'production') {
5482
+ validateConfig(untrustedConfig, configPropertyNames);
5483
+ }
5484
+ const config = typeCheckConfig$5(untrustedConfig);
5485
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
5486
+ return null;
5487
+ }
5488
+ return config;
5489
+ }
5490
+ function adapterFragment$3(luvio, config) {
5491
+ createResourceParams$5(config);
5492
+ return select$6();
5493
+ }
5494
+ function onFetchResponseSuccess$3(luvio, config, resourceParams, response) {
5495
+ const snapshot = ingestSuccess$5(luvio, resourceParams, response, {
5496
+ config,
5497
+ resolve: () => buildNetworkSnapshot$5(luvio, config, snapshotRefreshOptions)
5498
+ });
5499
+ return luvio.storeBroadcast().then(() => snapshot);
5500
+ }
5501
+ function onFetchResponseError$3(luvio, config, resourceParams, response) {
5502
+ const snapshot = ingestError$3(luvio, resourceParams, response, {
5503
+ config,
5504
+ resolve: () => buildNetworkSnapshot$5(luvio, config, snapshotRefreshOptions)
5505
+ });
5506
+ return luvio.storeBroadcast().then(() => snapshot);
5507
+ }
5508
+ function buildNetworkSnapshot$5(luvio, config, options) {
5509
+ const resourceParams = createResourceParams$5(config);
5510
+ const request = createResourceRequest$5(resourceParams);
5511
+ return luvio.dispatchResourceRequest(request, options)
5512
+ .then((response) => {
5513
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$3(luvio, config, resourceParams, response), () => {
5514
+ const cache = new StoreKeyMap();
5515
+ getResponseCacheKeys$5(cache, luvio, resourceParams, response.body);
5516
+ return cache;
5517
+ });
5518
+ }, (response) => {
5519
+ return luvio.handleErrorResponse(() => onFetchResponseError$3(luvio, config, resourceParams, response));
5520
+ });
5521
+ }
5522
+ function buildNetworkSnapshotCachePolicy$3(context, coercedAdapterRequestContext) {
5523
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$5, undefined, false);
5524
+ }
5525
+ function buildCachedSnapshotCachePolicy$3(context, storeLookup) {
5526
+ const { luvio, config } = context;
5527
+ const selector = {
5528
+ recordId: keyBuilder$6(luvio, config),
5529
+ node: adapterFragment$3(luvio, config),
5530
+ variables: {},
5531
+ };
5532
+ const cacheSnapshot = storeLookup(selector, {
5533
+ config,
5534
+ resolve: () => buildNetworkSnapshot$5(luvio, config, snapshotRefreshOptions)
5535
+ });
5536
+ return cacheSnapshot;
5537
+ }
5538
+ const getPromptTemplateAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplate(untrustedConfig, requestContext) {
5539
+ const config = validateAdapterConfig$5(untrustedConfig, getPromptTemplate_ConfigPropertyNames);
5540
+ // Invalid or incomplete config
5541
+ if (config === null) {
5542
+ return null;
5543
+ }
5544
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
5545
+ buildCachedSnapshotCachePolicy$3, buildNetworkSnapshotCachePolicy$3);
5546
+ };
5547
+
5548
+ function select$5(luvio, params) {
5549
+ return select$7();
5550
+ }
5551
+ function keyBuilder$5(luvio, params) {
5552
+ return keyPrefix + '::EinsteinPromptRecordRepresentation:(' + 'includingContent:' + params.queryParams.includingContent + ',' + 'includingVersionDetail:' + params.queryParams.includingVersionDetail + ',' + 'promptTemplateDevName:' + params.urlParams.promptTemplateDevName + ',' + 'versionId:' + params.urlParams.versionId + ')';
5553
+ }
5554
+ function getResponseCacheKeys$4(storeKeyMap, luvio, resourceParams, response) {
5555
+ getTypeCacheKeys$1(storeKeyMap, luvio, response, () => keyBuilder$5(luvio, resourceParams));
5556
+ }
5557
+ function ingestSuccess$4(luvio, resourceParams, response, snapshotRefresh) {
5558
+ const { body } = response;
5559
+ const key = keyBuilder$5(luvio, resourceParams);
5560
+ luvio.storeIngest(key, ingest$1, body);
5561
+ const snapshot = luvio.storeLookup({
5562
+ recordId: key,
5563
+ node: select$5(),
5564
+ variables: {},
5565
+ }, snapshotRefresh);
5566
+ if (process.env.NODE_ENV !== 'production') {
5567
+ if (snapshot.state !== 'Fulfilled') {
5568
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
5569
+ }
5570
+ }
5571
+ deepFreeze(snapshot.data);
5572
+ return snapshot;
5573
+ }
5574
+ function ingestError$2(luvio, params, error, snapshotRefresh) {
5575
+ const key = keyBuilder$5(luvio, params);
5576
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
5577
+ const storeMetadataParams = {
5578
+ ttl: TTL$1,
5579
+ namespace: keyPrefix,
5580
+ version: VERSION$1,
5581
+ representationName: RepresentationType$1
5582
+ };
5583
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
5584
+ return errorSnapshot;
5585
+ }
5586
+ function createResourceRequest$4(config) {
5587
+ const headers = {};
5588
+ return {
5589
+ baseUri: '/services/data/v65.0',
5590
+ basePath: '/einstein/prompt-templates/' + config.urlParams.promptTemplateDevName + '/versions/' + config.urlParams.versionId + '',
5591
+ method: 'get',
5592
+ body: null,
5593
+ urlParams: config.urlParams,
5594
+ queryParams: config.queryParams,
5595
+ headers,
5596
+ priority: 'normal',
5597
+ };
5598
+ }
5599
+
5600
+ const adapterName$4 = 'getPromptTemplateVersion';
5601
+ const getPromptTemplateVersion_ConfigPropertyMetadata = [
5602
+ generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
5603
+ generateParamConfigMetadata('versionId', true, 0 /* UrlParameter */, 0 /* String */),
5604
+ generateParamConfigMetadata('includingContent', false, 1 /* QueryParameter */, 1 /* Boolean */),
5605
+ generateParamConfigMetadata('includingVersionDetail', false, 1 /* QueryParameter */, 1 /* Boolean */),
5606
+ ];
5607
+ const getPromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$4, getPromptTemplateVersion_ConfigPropertyMetadata);
5608
+ const createResourceParams$4 = /*#__PURE__*/ createResourceParams$h(getPromptTemplateVersion_ConfigPropertyMetadata);
5609
+ function keyBuilder$4(luvio, config) {
5610
+ const resourceParams = createResourceParams$4(config);
5611
+ return keyBuilder$5(luvio, resourceParams);
5612
+ }
5613
+ function typeCheckConfig$4(untrustedConfig) {
5614
+ const config = {};
5615
+ typeCheckConfig$h(untrustedConfig, config, getPromptTemplateVersion_ConfigPropertyMetadata);
5616
+ return config;
5617
+ }
5618
+ function validateAdapterConfig$4(untrustedConfig, configPropertyNames) {
5619
+ if (!untrustedIsObject(untrustedConfig)) {
5620
+ return null;
4014
5621
  }
4015
- return true;
4016
- }
4017
- const ingest$1 = function EinsteinPromptRecordRepresentationIngest(input, path, luvio, store, timestamp) {
4018
5622
  if (process.env.NODE_ENV !== 'production') {
4019
- const validateError = validate$1(input);
4020
- if (validateError !== null) {
4021
- throw validateError;
4022
- }
5623
+ validateConfig(untrustedConfig, configPropertyNames);
4023
5624
  }
4024
- const key = path.fullPath;
4025
- const ttlToUse = TTL$1;
4026
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$1, "EinsteinLLM", VERSION$1, RepresentationType$1, equals$1);
4027
- return createLink(key);
4028
- };
4029
- function getTypeCacheKeys$1(rootKeySet, luvio, input, fullPathFactory) {
4030
- // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
4031
- const rootKey = fullPathFactory();
4032
- rootKeySet.set(rootKey, {
4033
- namespace: keyPrefix,
4034
- representationName: RepresentationType$1,
4035
- mergeable: false
5625
+ const config = typeCheckConfig$4(untrustedConfig);
5626
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
5627
+ return null;
5628
+ }
5629
+ return config;
5630
+ }
5631
+ function adapterFragment$2(luvio, config) {
5632
+ createResourceParams$4(config);
5633
+ return select$5();
5634
+ }
5635
+ function onFetchResponseSuccess$2(luvio, config, resourceParams, response) {
5636
+ const snapshot = ingestSuccess$4(luvio, resourceParams, response, {
5637
+ config,
5638
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
5639
+ });
5640
+ return luvio.storeBroadcast().then(() => snapshot);
5641
+ }
5642
+ function onFetchResponseError$2(luvio, config, resourceParams, response) {
5643
+ const snapshot = ingestError$2(luvio, resourceParams, response, {
5644
+ config,
5645
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
5646
+ });
5647
+ return luvio.storeBroadcast().then(() => snapshot);
5648
+ }
5649
+ function buildNetworkSnapshot$4(luvio, config, options) {
5650
+ const resourceParams = createResourceParams$4(config);
5651
+ const request = createResourceRequest$4(resourceParams);
5652
+ return luvio.dispatchResourceRequest(request, options)
5653
+ .then((response) => {
5654
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$2(luvio, config, resourceParams, response), () => {
5655
+ const cache = new StoreKeyMap();
5656
+ getResponseCacheKeys$4(cache, luvio, resourceParams, response.body);
5657
+ return cache;
5658
+ });
5659
+ }, (response) => {
5660
+ return luvio.handleErrorResponse(() => onFetchResponseError$2(luvio, config, resourceParams, response));
5661
+ });
5662
+ }
5663
+ function buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext) {
5664
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$4, undefined, false);
5665
+ }
5666
+ function buildCachedSnapshotCachePolicy$2(context, storeLookup) {
5667
+ const { luvio, config } = context;
5668
+ const selector = {
5669
+ recordId: keyBuilder$4(luvio, config),
5670
+ node: adapterFragment$2(luvio, config),
5671
+ variables: {},
5672
+ };
5673
+ const cacheSnapshot = storeLookup(selector, {
5674
+ config,
5675
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
4036
5676
  });
5677
+ return cacheSnapshot;
4037
5678
  }
5679
+ const getPromptTemplateVersionAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplateVersion(untrustedConfig, requestContext) {
5680
+ const config = validateAdapterConfig$4(untrustedConfig, getPromptTemplateVersion_ConfigPropertyNames);
5681
+ // Invalid or incomplete config
5682
+ if (config === null) {
5683
+ return null;
5684
+ }
5685
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
5686
+ buildCachedSnapshotCachePolicy$2, buildNetworkSnapshotCachePolicy$2);
5687
+ };
4038
5688
 
4039
- function select$3(luvio, params) {
4040
- return select$4();
5689
+ function select$4(luvio, params) {
5690
+ return select$7();
4041
5691
  }
4042
5692
  function keyBuilder$3(luvio, params) {
4043
- return keyPrefix + '::EinsteinPromptRecordRepresentation:(' + 'versionId:' + params.queryParams.versionId + ',' + 'promptTemplateDevName:' + params.urlParams.promptTemplateDevName + ')';
5693
+ return keyPrefix + '::EinsteinPromptRecordRepresentation:(' + 'includingContent:' + params.queryParams.includingContent + ',' + 'includingVersionDetail:' + params.queryParams.includingVersionDetail + ',' + 'promptTemplateDevName:' + params.urlParams.promptTemplateDevName + ')';
4044
5694
  }
4045
- function getResponseCacheKeys$2(storeKeyMap, luvio, resourceParams, response) {
5695
+ function getResponseCacheKeys$3(storeKeyMap, luvio, resourceParams, response) {
4046
5696
  getTypeCacheKeys$1(storeKeyMap, luvio, response, () => keyBuilder$3(luvio, resourceParams));
4047
5697
  }
4048
- function ingestSuccess$2(luvio, resourceParams, response, snapshotRefresh) {
5698
+ function ingestSuccess$3(luvio, resourceParams, response, snapshotRefresh) {
4049
5699
  const { body } = response;
4050
5700
  const key = keyBuilder$3(luvio, resourceParams);
4051
5701
  luvio.storeIngest(key, ingest$1, body);
4052
5702
  const snapshot = luvio.storeLookup({
4053
5703
  recordId: key,
4054
- node: select$3(),
5704
+ node: select$4(),
4055
5705
  variables: {},
4056
5706
  }, snapshotRefresh);
4057
5707
  if (process.env.NODE_ENV !== 'production') {
@@ -4074,11 +5724,11 @@ function ingestError$1(luvio, params, error, snapshotRefresh) {
4074
5724
  luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
4075
5725
  return errorSnapshot;
4076
5726
  }
4077
- function createResourceRequest$2(config) {
5727
+ function createResourceRequest$3(config) {
4078
5728
  const headers = {};
4079
5729
  return {
4080
5730
  baseUri: '/services/data/v65.0',
4081
- basePath: '/einstein/prompt-templates/' + config.urlParams.promptTemplateDevName + '',
5731
+ basePath: '/einstein/prompt-templates/' + config.urlParams.promptTemplateDevName + '/versions',
4082
5732
  method: 'get',
4083
5733
  body: null,
4084
5734
  urlParams: config.urlParams,
@@ -4088,61 +5738,62 @@ function createResourceRequest$2(config) {
4088
5738
  };
4089
5739
  }
4090
5740
 
4091
- const adapterName$2 = 'getPromptTemplate';
4092
- const getPromptTemplate_ConfigPropertyMetadata = [
5741
+ const adapterName$3 = 'getPromptTemplateVersions';
5742
+ const getPromptTemplateVersions_ConfigPropertyMetadata = [
4093
5743
  generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
4094
- generateParamConfigMetadata('versionId', false, 1 /* QueryParameter */, 0 /* String */),
5744
+ generateParamConfigMetadata('includingContent', false, 1 /* QueryParameter */, 1 /* Boolean */),
5745
+ generateParamConfigMetadata('includingVersionDetail', false, 1 /* QueryParameter */, 1 /* Boolean */),
4095
5746
  ];
4096
- const getPromptTemplate_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$2, getPromptTemplate_ConfigPropertyMetadata);
4097
- const createResourceParams$2 = /*#__PURE__*/ createResourceParams$a(getPromptTemplate_ConfigPropertyMetadata);
5747
+ const getPromptTemplateVersions_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$3, getPromptTemplateVersions_ConfigPropertyMetadata);
5748
+ const createResourceParams$3 = /*#__PURE__*/ createResourceParams$h(getPromptTemplateVersions_ConfigPropertyMetadata);
4098
5749
  function keyBuilder$2(luvio, config) {
4099
- const resourceParams = createResourceParams$2(config);
5750
+ const resourceParams = createResourceParams$3(config);
4100
5751
  return keyBuilder$3(luvio, resourceParams);
4101
5752
  }
4102
- function typeCheckConfig$2(untrustedConfig) {
5753
+ function typeCheckConfig$3(untrustedConfig) {
4103
5754
  const config = {};
4104
- typeCheckConfig$a(untrustedConfig, config, getPromptTemplate_ConfigPropertyMetadata);
5755
+ typeCheckConfig$h(untrustedConfig, config, getPromptTemplateVersions_ConfigPropertyMetadata);
4105
5756
  return config;
4106
5757
  }
4107
- function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
5758
+ function validateAdapterConfig$3(untrustedConfig, configPropertyNames) {
4108
5759
  if (!untrustedIsObject(untrustedConfig)) {
4109
5760
  return null;
4110
5761
  }
4111
5762
  if (process.env.NODE_ENV !== 'production') {
4112
5763
  validateConfig(untrustedConfig, configPropertyNames);
4113
5764
  }
4114
- const config = typeCheckConfig$2(untrustedConfig);
5765
+ const config = typeCheckConfig$3(untrustedConfig);
4115
5766
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
4116
5767
  return null;
4117
5768
  }
4118
5769
  return config;
4119
5770
  }
4120
5771
  function adapterFragment$1(luvio, config) {
4121
- createResourceParams$2(config);
4122
- return select$3();
5772
+ createResourceParams$3(config);
5773
+ return select$4();
4123
5774
  }
4124
5775
  function onFetchResponseSuccess$1(luvio, config, resourceParams, response) {
4125
- const snapshot = ingestSuccess$2(luvio, resourceParams, response, {
5776
+ const snapshot = ingestSuccess$3(luvio, resourceParams, response, {
4126
5777
  config,
4127
- resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
5778
+ resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
4128
5779
  });
4129
5780
  return luvio.storeBroadcast().then(() => snapshot);
4130
5781
  }
4131
5782
  function onFetchResponseError$1(luvio, config, resourceParams, response) {
4132
5783
  const snapshot = ingestError$1(luvio, resourceParams, response, {
4133
5784
  config,
4134
- resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
5785
+ resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
4135
5786
  });
4136
5787
  return luvio.storeBroadcast().then(() => snapshot);
4137
5788
  }
4138
- function buildNetworkSnapshot$2(luvio, config, options) {
4139
- const resourceParams = createResourceParams$2(config);
4140
- const request = createResourceRequest$2(resourceParams);
5789
+ function buildNetworkSnapshot$3(luvio, config, options) {
5790
+ const resourceParams = createResourceParams$3(config);
5791
+ const request = createResourceRequest$3(resourceParams);
4141
5792
  return luvio.dispatchResourceRequest(request, options)
4142
5793
  .then((response) => {
4143
5794
  return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => {
4144
5795
  const cache = new StoreKeyMap();
4145
- getResponseCacheKeys$2(cache, luvio, resourceParams, response.body);
5796
+ getResponseCacheKeys$3(cache, luvio, resourceParams, response.body);
4146
5797
  return cache;
4147
5798
  });
4148
5799
  }, (response) => {
@@ -4150,7 +5801,7 @@ function buildNetworkSnapshot$2(luvio, config, options) {
4150
5801
  });
4151
5802
  }
4152
5803
  function buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext) {
4153
- return buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext, buildNetworkSnapshot$2, undefined, false);
5804
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$3, undefined, false);
4154
5805
  }
4155
5806
  function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
4156
5807
  const { luvio, config } = context;
@@ -4161,12 +5812,12 @@ function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
4161
5812
  };
4162
5813
  const cacheSnapshot = storeLookup(selector, {
4163
5814
  config,
4164
- resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
5815
+ resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
4165
5816
  });
4166
5817
  return cacheSnapshot;
4167
5818
  }
4168
- const getPromptTemplateAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplate(untrustedConfig, requestContext) {
4169
- const config = validateAdapterConfig$2(untrustedConfig, getPromptTemplate_ConfigPropertyNames);
5819
+ const getPromptTemplateVersionsAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplateVersions(untrustedConfig, requestContext) {
5820
+ const config = validateAdapterConfig$3(untrustedConfig, getPromptTemplateVersions_ConfigPropertyNames);
4170
5821
  // Invalid or incomplete config
4171
5822
  if (config === null) {
4172
5823
  return null;
@@ -4216,7 +5867,7 @@ const RepresentationType = 'EinsteinPromptRecordCollectionOutputRepresentation';
4216
5867
  function normalize(input, existing, path, luvio, store, timestamp) {
4217
5868
  return input;
4218
5869
  }
4219
- const select$2 = function EinsteinPromptRecordCollectionOutputRepresentationSelect() {
5870
+ const select$3 = function EinsteinPromptRecordCollectionOutputRepresentationSelect() {
4220
5871
  return {
4221
5872
  kind: 'Fragment',
4222
5873
  version: VERSION,
@@ -4252,22 +5903,22 @@ function getTypeCacheKeys(rootKeySet, luvio, input, fullPathFactory) {
4252
5903
  });
4253
5904
  }
4254
5905
 
4255
- function select$1(luvio, params) {
4256
- return select$2();
5906
+ function select$2(luvio, params) {
5907
+ return select$3();
4257
5908
  }
4258
5909
  function keyBuilder$1(luvio, params) {
4259
5910
  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 + ')';
4260
5911
  }
4261
- function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
5912
+ function getResponseCacheKeys$2(storeKeyMap, luvio, resourceParams, response) {
4262
5913
  getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$1(luvio, resourceParams));
4263
5914
  }
4264
- function ingestSuccess$1(luvio, resourceParams, response, snapshotRefresh) {
5915
+ function ingestSuccess$2(luvio, resourceParams, response, snapshotRefresh) {
4265
5916
  const { body } = response;
4266
5917
  const key = keyBuilder$1(luvio, resourceParams);
4267
5918
  luvio.storeIngest(key, ingest, body);
4268
5919
  const snapshot = luvio.storeLookup({
4269
5920
  recordId: key,
4270
- node: select$1(),
5921
+ node: select$2(),
4271
5922
  variables: {},
4272
5923
  }, snapshotRefresh);
4273
5924
  if (process.env.NODE_ENV !== 'production') {
@@ -4290,7 +5941,7 @@ function ingestError(luvio, params, error, snapshotRefresh) {
4290
5941
  luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
4291
5942
  return errorSnapshot;
4292
5943
  }
4293
- function createResourceRequest$1(config) {
5944
+ function createResourceRequest$2(config) {
4294
5945
  const headers = {};
4295
5946
  return {
4296
5947
  baseUri: '/services/data/v65.0',
@@ -4304,7 +5955,7 @@ function createResourceRequest$1(config) {
4304
5955
  };
4305
5956
  }
4306
5957
 
4307
- const adapterName$1 = 'getPromptTemplates';
5958
+ const adapterName$2 = 'getPromptTemplates';
4308
5959
  const getPromptTemplates_ConfigPropertyMetadata = [
4309
5960
  generateParamConfigMetadata('isActive', false, 1 /* QueryParameter */, 1 /* Boolean */),
4310
5961
  generateParamConfigMetadata('fields', false, 1 /* QueryParameter */, 0 /* String */, true),
@@ -4315,56 +5966,56 @@ const getPromptTemplates_ConfigPropertyMetadata = [
4315
5966
  generateParamConfigMetadata('query', false, 1 /* QueryParameter */, 0 /* String */),
4316
5967
  generateParamConfigMetadata('sortBy', false, 1 /* QueryParameter */, 0 /* String */),
4317
5968
  ];
4318
- const getPromptTemplates_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, getPromptTemplates_ConfigPropertyMetadata);
4319
- const createResourceParams$1 = /*#__PURE__*/ createResourceParams$a(getPromptTemplates_ConfigPropertyMetadata);
5969
+ const getPromptTemplates_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$2, getPromptTemplates_ConfigPropertyMetadata);
5970
+ const createResourceParams$2 = /*#__PURE__*/ createResourceParams$h(getPromptTemplates_ConfigPropertyMetadata);
4320
5971
  function keyBuilder(luvio, config) {
4321
- const resourceParams = createResourceParams$1(config);
5972
+ const resourceParams = createResourceParams$2(config);
4322
5973
  return keyBuilder$1(luvio, resourceParams);
4323
5974
  }
4324
- function typeCheckConfig$1(untrustedConfig) {
5975
+ function typeCheckConfig$2(untrustedConfig) {
4325
5976
  const config = {};
4326
- typeCheckConfig$a(untrustedConfig, config, getPromptTemplates_ConfigPropertyMetadata);
5977
+ typeCheckConfig$h(untrustedConfig, config, getPromptTemplates_ConfigPropertyMetadata);
4327
5978
  return config;
4328
5979
  }
4329
- function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
5980
+ function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
4330
5981
  if (!untrustedIsObject(untrustedConfig)) {
4331
5982
  return null;
4332
5983
  }
4333
5984
  if (process.env.NODE_ENV !== 'production') {
4334
5985
  validateConfig(untrustedConfig, configPropertyNames);
4335
5986
  }
4336
- const config = typeCheckConfig$1(untrustedConfig);
5987
+ const config = typeCheckConfig$2(untrustedConfig);
4337
5988
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
4338
5989
  return null;
4339
5990
  }
4340
5991
  return config;
4341
5992
  }
4342
5993
  function adapterFragment(luvio, config) {
4343
- createResourceParams$1(config);
4344
- return select$1();
5994
+ createResourceParams$2(config);
5995
+ return select$2();
4345
5996
  }
4346
5997
  function onFetchResponseSuccess(luvio, config, resourceParams, response) {
4347
- const snapshot = ingestSuccess$1(luvio, resourceParams, response, {
5998
+ const snapshot = ingestSuccess$2(luvio, resourceParams, response, {
4348
5999
  config,
4349
- resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
6000
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
4350
6001
  });
4351
6002
  return luvio.storeBroadcast().then(() => snapshot);
4352
6003
  }
4353
6004
  function onFetchResponseError(luvio, config, resourceParams, response) {
4354
6005
  const snapshot = ingestError(luvio, resourceParams, response, {
4355
6006
  config,
4356
- resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
6007
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
4357
6008
  });
4358
6009
  return luvio.storeBroadcast().then(() => snapshot);
4359
6010
  }
4360
- function buildNetworkSnapshot$1(luvio, config, options) {
4361
- const resourceParams = createResourceParams$1(config);
4362
- const request = createResourceRequest$1(resourceParams);
6011
+ function buildNetworkSnapshot$2(luvio, config, options) {
6012
+ const resourceParams = createResourceParams$2(config);
6013
+ const request = createResourceRequest$2(resourceParams);
4363
6014
  return luvio.dispatchResourceRequest(request, options)
4364
6015
  .then((response) => {
4365
6016
  return luvio.handleSuccessResponse(() => onFetchResponseSuccess(luvio, config, resourceParams, response), () => {
4366
6017
  const cache = new StoreKeyMap();
4367
- getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
6018
+ getResponseCacheKeys$2(cache, luvio, resourceParams, response.body);
4368
6019
  return cache;
4369
6020
  });
4370
6021
  }, (response) => {
@@ -4372,7 +6023,7 @@ function buildNetworkSnapshot$1(luvio, config, options) {
4372
6023
  });
4373
6024
  }
4374
6025
  function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
4375
- return buildNetworkSnapshotCachePolicy$4(context, coercedAdapterRequestContext, buildNetworkSnapshot$1, undefined, false);
6026
+ return buildNetworkSnapshotCachePolicy$a(context, coercedAdapterRequestContext, buildNetworkSnapshot$2, undefined, false);
4376
6027
  }
4377
6028
  function buildCachedSnapshotCachePolicy(context, storeLookup) {
4378
6029
  const { luvio, config } = context;
@@ -4383,12 +6034,12 @@ function buildCachedSnapshotCachePolicy(context, storeLookup) {
4383
6034
  };
4384
6035
  const cacheSnapshot = storeLookup(selector, {
4385
6036
  config,
4386
- resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
6037
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
4387
6038
  });
4388
6039
  return cacheSnapshot;
4389
6040
  }
4390
6041
  const getPromptTemplatesAdapterFactory = (luvio) => function EinsteinLLM__getPromptTemplates(untrustedConfig, requestContext) {
4391
- const config = validateAdapterConfig$1(untrustedConfig, getPromptTemplates_ConfigPropertyNames);
6042
+ const config = validateAdapterConfig$2(untrustedConfig, getPromptTemplates_ConfigPropertyNames);
4392
6043
  // Invalid or incomplete config
4393
6044
  if (config === null) {
4394
6045
  return null;
@@ -4397,16 +6048,109 @@ const getPromptTemplatesAdapterFactory = (luvio) => function EinsteinLLM__getPro
4397
6048
  buildCachedSnapshotCachePolicy, buildNetworkSnapshotCachePolicy);
4398
6049
  };
4399
6050
 
6051
+ function select$1(luvio, params) {
6052
+ return select$l();
6053
+ }
6054
+ function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
6055
+ getTypeCacheKeys$6(storeKeyMap, luvio, response);
6056
+ }
6057
+ function ingestSuccess$1(luvio, resourceParams, response) {
6058
+ const { body } = response;
6059
+ const key = keyBuilderFromType(luvio, body);
6060
+ luvio.storeIngest(key, ingest$6, body);
6061
+ const snapshot = luvio.storeLookup({
6062
+ recordId: key,
6063
+ node: select$1(),
6064
+ variables: {},
6065
+ });
6066
+ if (process.env.NODE_ENV !== 'production') {
6067
+ if (snapshot.state !== 'Fulfilled') {
6068
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
6069
+ }
6070
+ }
6071
+ deepFreeze(snapshot.data);
6072
+ return snapshot;
6073
+ }
6074
+ function createResourceRequest$1(config) {
6075
+ const headers = {};
6076
+ return {
6077
+ baseUri: '/services/data/v65.0',
6078
+ basePath: '/einstein/prompt-templates/' + config.urlParams.promptTemplateDevName + '/versions/' + config.urlParams.versionId + '/status',
6079
+ method: 'put',
6080
+ body: null,
6081
+ urlParams: config.urlParams,
6082
+ queryParams: config.queryParams,
6083
+ headers,
6084
+ priority: 'normal',
6085
+ };
6086
+ }
6087
+
6088
+ const adapterName$1 = 'putEinsteinPromptTemplateVersionStatus';
6089
+ const putEinsteinPromptTemplateVersionStatus_ConfigPropertyMetadata = [
6090
+ generateParamConfigMetadata('promptTemplateDevName', true, 0 /* UrlParameter */, 0 /* String */),
6091
+ generateParamConfigMetadata('versionId', true, 0 /* UrlParameter */, 0 /* String */),
6092
+ generateParamConfigMetadata('action', false, 1 /* QueryParameter */, 0 /* String */),
6093
+ generateParamConfigMetadata('ignoreWarnings', false, 1 /* QueryParameter */, 1 /* Boolean */),
6094
+ ];
6095
+ const putEinsteinPromptTemplateVersionStatus_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, putEinsteinPromptTemplateVersionStatus_ConfigPropertyMetadata);
6096
+ const createResourceParams$1 = /*#__PURE__*/ createResourceParams$h(putEinsteinPromptTemplateVersionStatus_ConfigPropertyMetadata);
6097
+ function typeCheckConfig$1(untrustedConfig) {
6098
+ const config = {};
6099
+ typeCheckConfig$h(untrustedConfig, config, putEinsteinPromptTemplateVersionStatus_ConfigPropertyMetadata);
6100
+ return config;
6101
+ }
6102
+ function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
6103
+ if (!untrustedIsObject(untrustedConfig)) {
6104
+ return null;
6105
+ }
6106
+ if (process.env.NODE_ENV !== 'production') {
6107
+ validateConfig(untrustedConfig, configPropertyNames);
6108
+ }
6109
+ const config = typeCheckConfig$1(untrustedConfig);
6110
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
6111
+ return null;
6112
+ }
6113
+ return config;
6114
+ }
6115
+ function buildNetworkSnapshot$1(luvio, config, options) {
6116
+ const resourceParams = createResourceParams$1(config);
6117
+ const request = createResourceRequest$1(resourceParams);
6118
+ return luvio.dispatchResourceRequest(request, options)
6119
+ .then((response) => {
6120
+ return luvio.handleSuccessResponse(() => {
6121
+ const snapshot = ingestSuccess$1(luvio, resourceParams, response);
6122
+ return luvio.storeBroadcast().then(() => snapshot);
6123
+ }, () => {
6124
+ const cache = new StoreKeyMap();
6125
+ getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
6126
+ return cache;
6127
+ });
6128
+ }, (response) => {
6129
+ deepFreeze(response);
6130
+ throw response;
6131
+ });
6132
+ }
6133
+ const putEinsteinPromptTemplateVersionStatusAdapterFactory = (luvio) => {
6134
+ return function putEinsteinPromptTemplateVersionStatus(untrustedConfig) {
6135
+ const config = validateAdapterConfig$1(untrustedConfig, putEinsteinPromptTemplateVersionStatus_ConfigPropertyNames);
6136
+ // Invalid or incomplete config
6137
+ if (config === null) {
6138
+ throw new Error('Invalid config for "putEinsteinPromptTemplateVersionStatus"');
6139
+ }
6140
+ return buildNetworkSnapshot$1(luvio, config);
6141
+ };
6142
+ };
6143
+
4400
6144
  function select(luvio, params) {
4401
- return select$b();
6145
+ return select$l();
4402
6146
  }
4403
6147
  function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
4404
- getTypeCacheKeys$3(storeKeyMap, luvio, response);
6148
+ getTypeCacheKeys$6(storeKeyMap, luvio, response);
4405
6149
  }
4406
6150
  function ingestSuccess(luvio, resourceParams, response) {
4407
6151
  const { body } = response;
4408
6152
  const key = keyBuilderFromType(luvio, body);
4409
- luvio.storeIngest(key, ingest$3, body);
6153
+ luvio.storeIngest(key, ingest$6, body);
4410
6154
  const snapshot = luvio.storeLookup({
4411
6155
  recordId: key,
4412
6156
  node: select(),
@@ -4440,15 +6184,14 @@ const updatePromptTemplateVersion_ConfigPropertyMetadata = [
4440
6184
  generateParamConfigMetadata('versionId', true, 0 /* UrlParameter */, 0 /* String */),
4441
6185
  generateParamConfigMetadata('apiName', true, 2 /* Body */, 0 /* String */),
4442
6186
  generateParamConfigMetadata('childRelationships', true, 2 /* Body */, 4 /* Unsupported */),
4443
- generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */, true),
6187
+ generateParamConfigMetadata('fields', true, 2 /* Body */, 4 /* Unsupported */),
4444
6188
  generateParamConfigMetadata('id', false, 2 /* Body */, 0 /* String */),
4445
- generateParamConfigMetadata('isStandard', true, 2 /* Body */, 1 /* Boolean */),
4446
6189
  ];
4447
6190
  const updatePromptTemplateVersion_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, updatePromptTemplateVersion_ConfigPropertyMetadata);
4448
- const createResourceParams = /*#__PURE__*/ createResourceParams$a(updatePromptTemplateVersion_ConfigPropertyMetadata);
6191
+ const createResourceParams = /*#__PURE__*/ createResourceParams$h(updatePromptTemplateVersion_ConfigPropertyMetadata);
4449
6192
  function typeCheckConfig(untrustedConfig) {
4450
6193
  const config = {};
4451
- typeCheckConfig$a(untrustedConfig, config, updatePromptTemplateVersion_ConfigPropertyMetadata);
6194
+ typeCheckConfig$h(untrustedConfig, config, updatePromptTemplateVersion_ConfigPropertyMetadata);
4452
6195
  const untrustedConfig_childRelationships = untrustedConfig.childRelationships;
4453
6196
  if (untrustedIsObject(untrustedConfig_childRelationships)) {
4454
6197
  const untrustedConfig_childRelationships_object = {};
@@ -4465,26 +6208,19 @@ function typeCheckConfig(untrustedConfig) {
4465
6208
  }
4466
6209
  }
4467
6210
  const untrustedConfig_fields = untrustedConfig.fields;
4468
- if (ArrayIsArray$1(untrustedConfig_fields)) {
4469
- const untrustedConfig_fields_array = [];
4470
- for (let i = 0, arrayLength = untrustedConfig_fields.length; i < arrayLength; i++) {
4471
- const untrustedConfig_fields_item = untrustedConfig_fields[i];
4472
- if (untrustedIsObject(untrustedConfig_fields_item)) {
4473
- const untrustedConfig_fields_item_object = {};
4474
- const untrustedConfig_fields_item_keys = Object.keys(untrustedConfig_fields_item);
4475
- for (let i = 0, arrayLength = untrustedConfig_fields_item_keys.length; i < arrayLength; i++) {
4476
- const key = untrustedConfig_fields_item_keys[i];
4477
- const untrustedConfig_fields_item_prop = untrustedConfig_fields_item[key];
4478
- if (untrustedConfig_fields_item_object !== undefined) {
4479
- untrustedConfig_fields_item_object[key] = untrustedConfig_fields_item_prop;
4480
- }
4481
- }
4482
- if (untrustedConfig_fields_item_object !== undefined && Object.keys(untrustedConfig_fields_item_object).length >= 0) {
4483
- untrustedConfig_fields_array.push(untrustedConfig_fields_item_object);
4484
- }
6211
+ if (untrustedIsObject(untrustedConfig_fields)) {
6212
+ const untrustedConfig_fields_object = {};
6213
+ const untrustedConfig_fields_keys = Object.keys(untrustedConfig_fields);
6214
+ for (let i = 0, arrayLength = untrustedConfig_fields_keys.length; i < arrayLength; i++) {
6215
+ const key = untrustedConfig_fields_keys[i];
6216
+ const untrustedConfig_fields_prop = untrustedConfig_fields[key];
6217
+ if (untrustedConfig_fields_object !== undefined) {
6218
+ untrustedConfig_fields_object[key] = untrustedConfig_fields_prop;
4485
6219
  }
4486
6220
  }
4487
- config.fields = untrustedConfig_fields_array;
6221
+ if (untrustedConfig_fields_object !== undefined && Object.keys(untrustedConfig_fields_object).length >= 0) {
6222
+ config.fields = untrustedConfig_fields_object;
6223
+ }
4488
6224
  }
4489
6225
  return config;
4490
6226
  }
@@ -4536,23 +6272,62 @@ let createGenerations;
4536
6272
  let createGenerationsForPromptTemplate;
4537
6273
  let createPromptTemplate;
4538
6274
  let createPromptTemplateVersion;
6275
+ let getDataProviderInstanceConfig;
6276
+ let getDataProviderTypeConfigs;
6277
+ let getDataProviders;
6278
+ let getInputMappedDataProviders;
4539
6279
  let getOutputLanguages;
4540
6280
  let getPromptTemplate;
6281
+ let getPromptTemplateVersion;
6282
+ let getPromptTemplateVersions;
4541
6283
  let getPromptTemplates;
6284
+ let putEinsteinPromptTemplateVersionStatus;
4542
6285
  let updatePromptTemplateVersion;
4543
6286
  // Imperative GET Adapters
4544
6287
  let createEmbeddings_imperative;
6288
+ let getDataProviderInstanceConfig_imperative;
6289
+ let getDataProviderTypeConfigs_imperative;
6290
+ let getDataProviders_imperative;
6291
+ let getInputMappedDataProviders_imperative;
4545
6292
  let getOutputLanguages_imperative;
4546
6293
  let getPromptTemplate_imperative;
6294
+ let getPromptTemplateVersion_imperative;
6295
+ let getPromptTemplateVersions_imperative;
4547
6296
  let getPromptTemplates_imperative;
4548
6297
  // Adapter Metadata
4549
6298
  const createEmbeddingsMetadata = { apiFamily: 'EinsteinLLM', name: 'createEmbeddings', ttl: 100 };
6299
+ const getDataProviderInstanceConfigMetadata = {
6300
+ apiFamily: 'EinsteinLLM',
6301
+ name: 'getDataProviderInstanceConfig',
6302
+ ttl: 300,
6303
+ };
6304
+ const getDataProviderTypeConfigsMetadata = {
6305
+ apiFamily: 'EinsteinLLM',
6306
+ name: 'getDataProviderTypeConfigs',
6307
+ ttl: 300,
6308
+ };
6309
+ const getDataProvidersMetadata = { apiFamily: 'EinsteinLLM', name: 'getDataProviders', ttl: 300 };
6310
+ const getInputMappedDataProvidersMetadata = {
6311
+ apiFamily: 'EinsteinLLM',
6312
+ name: 'getInputMappedDataProviders',
6313
+ ttl: 300,
6314
+ };
4550
6315
  const getOutputLanguagesMetadata = {
4551
6316
  apiFamily: 'EinsteinLLM',
4552
6317
  name: 'getOutputLanguages',
4553
6318
  ttl: 100,
4554
6319
  };
4555
6320
  const getPromptTemplateMetadata = { apiFamily: 'EinsteinLLM', name: 'getPromptTemplate', ttl: 100 };
6321
+ const getPromptTemplateVersionMetadata = {
6322
+ apiFamily: 'EinsteinLLM',
6323
+ name: 'getPromptTemplateVersion',
6324
+ ttl: 100,
6325
+ };
6326
+ const getPromptTemplateVersionsMetadata = {
6327
+ apiFamily: 'EinsteinLLM',
6328
+ name: 'getPromptTemplateVersions',
6329
+ ttl: 100,
6330
+ };
4556
6331
  const getPromptTemplatesMetadata = {
4557
6332
  apiFamily: 'EinsteinLLM',
4558
6333
  name: 'getPromptTemplates',
@@ -4562,8 +6337,14 @@ const getPromptTemplatesMetadata = {
4562
6337
  function bindExportsTo(luvio) {
4563
6338
  // LDS Adapters
4564
6339
  const createEmbeddings_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'createEmbeddings', createEmbeddingsAdapterFactory), createEmbeddingsMetadata);
6340
+ const getDataProviderInstanceConfig_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getDataProviderInstanceConfig', getDataProviderInstanceConfigAdapterFactory), getDataProviderInstanceConfigMetadata);
6341
+ const getDataProviderTypeConfigs_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getDataProviderTypeConfigs', getDataProviderTypeConfigsAdapterFactory), getDataProviderTypeConfigsMetadata);
6342
+ const getDataProviders_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getDataProviders', getDataProvidersAdapterFactory), getDataProvidersMetadata);
6343
+ const getInputMappedDataProviders_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getInputMappedDataProviders', getInputMappedDataProvidersAdapterFactory), getInputMappedDataProvidersMetadata);
4565
6344
  const getOutputLanguages_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getOutputLanguages', getOutputLanguagesAdapterFactory), getOutputLanguagesMetadata);
4566
6345
  const getPromptTemplate_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getPromptTemplate', getPromptTemplateAdapterFactory), getPromptTemplateMetadata);
6346
+ const getPromptTemplateVersion_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getPromptTemplateVersion', getPromptTemplateVersionAdapterFactory), getPromptTemplateVersionMetadata);
6347
+ const getPromptTemplateVersions_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getPromptTemplateVersions', getPromptTemplateVersionsAdapterFactory), getPromptTemplateVersionsMetadata);
4567
6348
  const getPromptTemplates_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getPromptTemplates', getPromptTemplatesAdapterFactory), getPromptTemplatesMetadata);
4568
6349
  function unwrapSnapshotData(factory) {
4569
6350
  const adapter = factory(luvio);
@@ -4576,14 +6357,27 @@ function bindExportsTo(luvio) {
4576
6357
  createGenerationsForPromptTemplate: unwrapSnapshotData(createGenerationsForPromptTemplateAdapterFactory),
4577
6358
  createPromptTemplate: unwrapSnapshotData(createPromptTemplateAdapterFactory),
4578
6359
  createPromptTemplateVersion: unwrapSnapshotData(createPromptTemplateVersionAdapterFactory),
6360
+ getDataProviderInstanceConfig: createWireAdapterConstructor(luvio, getDataProviderInstanceConfig_ldsAdapter, getDataProviderInstanceConfigMetadata),
6361
+ getDataProviderTypeConfigs: createWireAdapterConstructor(luvio, getDataProviderTypeConfigs_ldsAdapter, getDataProviderTypeConfigsMetadata),
6362
+ getDataProviders: createWireAdapterConstructor(luvio, getDataProviders_ldsAdapter, getDataProvidersMetadata),
6363
+ getInputMappedDataProviders: createWireAdapterConstructor(luvio, getInputMappedDataProviders_ldsAdapter, getInputMappedDataProvidersMetadata),
4579
6364
  getOutputLanguages: createWireAdapterConstructor(luvio, getOutputLanguages_ldsAdapter, getOutputLanguagesMetadata),
4580
6365
  getPromptTemplate: createWireAdapterConstructor(luvio, getPromptTemplate_ldsAdapter, getPromptTemplateMetadata),
6366
+ getPromptTemplateVersion: createWireAdapterConstructor(luvio, getPromptTemplateVersion_ldsAdapter, getPromptTemplateVersionMetadata),
6367
+ getPromptTemplateVersions: createWireAdapterConstructor(luvio, getPromptTemplateVersions_ldsAdapter, getPromptTemplateVersionsMetadata),
4581
6368
  getPromptTemplates: createWireAdapterConstructor(luvio, getPromptTemplates_ldsAdapter, getPromptTemplatesMetadata),
6369
+ putEinsteinPromptTemplateVersionStatus: unwrapSnapshotData(putEinsteinPromptTemplateVersionStatusAdapterFactory),
4582
6370
  updatePromptTemplateVersion: unwrapSnapshotData(updatePromptTemplateVersionAdapterFactory),
4583
6371
  // Imperative GET Adapters
4584
6372
  createEmbeddings_imperative: createImperativeAdapter(luvio, createEmbeddings_ldsAdapter, createEmbeddingsMetadata),
6373
+ getDataProviderInstanceConfig_imperative: createImperativeAdapter(luvio, getDataProviderInstanceConfig_ldsAdapter, getDataProviderInstanceConfigMetadata),
6374
+ getDataProviderTypeConfigs_imperative: createImperativeAdapter(luvio, getDataProviderTypeConfigs_ldsAdapter, getDataProviderTypeConfigsMetadata),
6375
+ getDataProviders_imperative: createImperativeAdapter(luvio, getDataProviders_ldsAdapter, getDataProvidersMetadata),
6376
+ getInputMappedDataProviders_imperative: createImperativeAdapter(luvio, getInputMappedDataProviders_ldsAdapter, getInputMappedDataProvidersMetadata),
4585
6377
  getOutputLanguages_imperative: createImperativeAdapter(luvio, getOutputLanguages_ldsAdapter, getOutputLanguagesMetadata),
4586
6378
  getPromptTemplate_imperative: createImperativeAdapter(luvio, getPromptTemplate_ldsAdapter, getPromptTemplateMetadata),
6379
+ getPromptTemplateVersion_imperative: createImperativeAdapter(luvio, getPromptTemplateVersion_ldsAdapter, getPromptTemplateVersionMetadata),
6380
+ getPromptTemplateVersions_imperative: createImperativeAdapter(luvio, getPromptTemplateVersions_ldsAdapter, getPromptTemplateVersionsMetadata),
4587
6381
  getPromptTemplates_imperative: createImperativeAdapter(luvio, getPromptTemplates_ldsAdapter, getPromptTemplatesMetadata),
4588
6382
  // Notify Update Availables
4589
6383
  };
@@ -4596,16 +6390,29 @@ withDefaultLuvio((luvio) => {
4596
6390
  createGenerationsForPromptTemplate,
4597
6391
  createPromptTemplate,
4598
6392
  createPromptTemplateVersion,
6393
+ getDataProviderInstanceConfig,
6394
+ getDataProviderTypeConfigs,
6395
+ getDataProviders,
6396
+ getInputMappedDataProviders,
4599
6397
  getOutputLanguages,
4600
6398
  getPromptTemplate,
6399
+ getPromptTemplateVersion,
6400
+ getPromptTemplateVersions,
4601
6401
  getPromptTemplates,
6402
+ putEinsteinPromptTemplateVersionStatus,
4602
6403
  updatePromptTemplateVersion,
4603
6404
  createEmbeddings_imperative,
6405
+ getDataProviderInstanceConfig_imperative,
6406
+ getDataProviderTypeConfigs_imperative,
6407
+ getDataProviders_imperative,
6408
+ getInputMappedDataProviders_imperative,
4604
6409
  getOutputLanguages_imperative,
4605
6410
  getPromptTemplate_imperative,
6411
+ getPromptTemplateVersion_imperative,
6412
+ getPromptTemplateVersions_imperative,
4606
6413
  getPromptTemplates_imperative,
4607
6414
  } = bindExportsTo(luvio));
4608
6415
  });
4609
6416
 
4610
- export { createEmbeddings, createEmbeddings_imperative, createFeedback, createGenerations, createGenerationsForPromptTemplate, createPromptTemplate, createPromptTemplateVersion, getOutputLanguages, getOutputLanguages_imperative, getPromptTemplate, getPromptTemplate_imperative, getPromptTemplates, getPromptTemplates_imperative, updatePromptTemplateVersion };
4611
- // version: 1.380.0-dev1-b7c5fad9db
6417
+ export { createEmbeddings, createEmbeddings_imperative, createFeedback, createGenerations, createGenerationsForPromptTemplate, createPromptTemplate, createPromptTemplateVersion, getDataProviderInstanceConfig, getDataProviderInstanceConfig_imperative, getDataProviderTypeConfigs, getDataProviderTypeConfigs_imperative, getDataProviders, getDataProviders_imperative, getInputMappedDataProviders, getInputMappedDataProviders_imperative, getOutputLanguages, getOutputLanguages_imperative, getPromptTemplate, getPromptTemplateVersion, getPromptTemplateVersion_imperative, getPromptTemplateVersions, getPromptTemplateVersions_imperative, getPromptTemplate_imperative, getPromptTemplates, getPromptTemplates_imperative, putEinsteinPromptTemplateVersionStatus, updatePromptTemplateVersion };
6418
+ // version: 1.380.0-dev10-0a2876c461