@valerypopoff/rivet2-core 2.32.0 → 2.33.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5449,6 +5449,7 @@ function fromSerializedNode(serializedNode) {
5449
5449
 
5450
5450
  // src/utils/serialization/serialization_v4.ts
5451
5451
  var import_lodash_es2 = require("lodash");
5452
+ var import_safe_stable_stringify3 = __toESM(require("safe-stable-stringify"), 1);
5452
5453
 
5453
5454
  // src/model/chat-v2/llmChatV2NodeMigration.ts
5454
5455
  function normalizeSerializedLLMTemperatureData(nodeType, data) {
@@ -5534,6 +5535,9 @@ function graphV4Deserializer(data) {
5534
5535
  return fromSerializedGraph2(serializedGraph);
5535
5536
  }
5536
5537
  function projectV4Serializer(project, attachedData) {
5538
+ return wrapInYamlEnvelope(4, prepareSerializedProject(project, attachedData));
5539
+ }
5540
+ function prepareSerializedProject(project, attachedData) {
5537
5541
  if (!isValidProjectStaticData(project.data)) {
5538
5542
  throw new Error("Project data must be a record of static-data strings");
5539
5543
  }
@@ -5547,7 +5551,7 @@ function projectV4Serializer(project, attachedData) {
5547
5551
  path: void 0
5548
5552
  }
5549
5553
  };
5550
- return wrapInYamlEnvelope(4, toSerializedProject(filteredProject, attachedData));
5554
+ return toSerializedProject(filteredProject, attachedData);
5551
5555
  }
5552
5556
  function graphV4Serializer(graph) {
5553
5557
  return wrapInYamlEnvelope(4, toSerializedGraph(graph));
@@ -6231,12 +6235,12 @@ function parseProviderJsonChunk(provider, chunk) {
6231
6235
  }
6232
6236
 
6233
6237
  // src/utils/projectComparison/connections.ts
6234
- var import_safe_stable_stringify4 = __toESM(require("safe-stable-stringify"), 1);
6238
+ var import_safe_stable_stringify5 = __toESM(require("safe-stable-stringify"), 1);
6235
6239
 
6236
6240
  // src/utils/projectComparison/values.ts
6237
- var import_safe_stable_stringify3 = __toESM(require("safe-stable-stringify"), 1);
6241
+ var import_safe_stable_stringify4 = __toESM(require("safe-stable-stringify"), 1);
6238
6242
  function areComparisonValuesEqual(left, right) {
6239
- return (0, import_safe_stable_stringify3.default)(left) === (0, import_safe_stable_stringify3.default)(right);
6243
+ return (0, import_safe_stable_stringify4.default)(left) === (0, import_safe_stable_stringify4.default)(right);
6240
6244
  }
6241
6245
  function getChangedValueComparisons(path, before, after) {
6242
6246
  if (areComparisonValuesEqual(before, after)) {
@@ -6281,7 +6285,7 @@ function formatComparisonPath(path) {
6281
6285
 
6282
6286
  // src/utils/projectComparison/connections.ts
6283
6287
  function getProjectConnectionComparisonKey(connection) {
6284
- return (0, import_safe_stable_stringify4.default)([
6288
+ return (0, import_safe_stable_stringify5.default)([
6285
6289
  connection.outputNodeId,
6286
6290
  connection.outputId,
6287
6291
  connection.inputNodeId,
@@ -22992,9 +22996,9 @@ function audioFormatToMediaType(format) {
22992
22996
 
22993
22997
  // src/model/LegacyChatEditorCache.ts
22994
22998
  var import_crypto_js2 = __toESM(require("crypto-js"), 1);
22995
- var import_safe_stable_stringify5 = __toESM(require("safe-stable-stringify"), 1);
22999
+ var import_safe_stable_stringify6 = __toESM(require("safe-stable-stringify"), 1);
22996
23000
  function buildLegacyChatEditorCacheKey(parts) {
22997
- const serialized = (0, import_safe_stable_stringify5.default)({ cacheVersion: 1, ...parts }) ?? "";
23001
+ const serialized = (0, import_safe_stable_stringify6.default)({ cacheVersion: 1, ...parts }) ?? "";
22998
23002
  return `legacy-chat:v1:sha256:${import_crypto_js2.default.SHA256(serialized).toString(import_crypto_js2.default.enc.Hex)}`;
22999
23003
  }
23000
23004
  function resolveLegacyChatEditorCache(params) {
@@ -29397,11 +29401,11 @@ function getLLMChatV2EditorCacheEligibility(data) {
29397
29401
  }
29398
29402
 
29399
29403
  // src/model/chat-v2/chatV2EditorCache.ts
29400
- var import_safe_stable_stringify6 = __toESM(require("safe-stable-stringify"), 1);
29404
+ var import_safe_stable_stringify7 = __toESM(require("safe-stable-stringify"), 1);
29401
29405
  var import_crypto_js3 = __toESM(require("crypto-js"), 1);
29402
29406
  function buildLLMChatV2EditorCacheKey(parts) {
29403
29407
  const { cacheVersion = 3, ...keyParts } = parts;
29404
- return (0, import_safe_stable_stringify6.default)({ cacheVersion, ...keyParts }) ?? "";
29408
+ return (0, import_safe_stable_stringify7.default)({ cacheVersion, ...keyParts }) ?? "";
29405
29409
  }
29406
29410
  function cloneLLMChatV2EditorCacheOutputs(outputs) {
29407
29411
  return cloneExecutionOutputs(outputs);
@@ -29434,7 +29438,7 @@ function fingerprintCustomProviderBaseURL(value) {
29434
29438
  }
29435
29439
  try {
29436
29440
  const endpoint = normalizeOpenAICompatibleEndpoint(value);
29437
- return (0, import_safe_stable_stringify6.default)({
29441
+ return (0, import_safe_stable_stringify7.default)({
29438
29442
  baseURL: endpoint.baseURL,
29439
29443
  endpointQuery: endpoint.endpointQuery.map(([key, queryValue]) => [key, fingerprintSecret(queryValue) ?? ""])
29440
29444
  }) ?? "";
@@ -29462,7 +29466,7 @@ function fingerprintRuntimeValueForCache(value) {
29462
29466
  if (value == null) {
29463
29467
  return void 0;
29464
29468
  }
29465
- return fingerprintSecret((0, import_safe_stable_stringify6.default)(value) ?? "");
29469
+ return fingerprintSecret((0, import_safe_stable_stringify7.default)(value) ?? "");
29466
29470
  }
29467
29471
  function fingerprintProfileChainForCache(data, profiles) {
29468
29472
  if (profiles == null) {
@@ -47042,7 +47046,7 @@ function getRetryDelayMs(retryAfter, attempt, deadline) {
47042
47046
 
47043
47047
  // src/model/classifier/profile.ts
47044
47048
  var import_crypto_js4 = __toESM(require("crypto-js"), 1);
47045
- var import_safe_stable_stringify7 = __toESM(require("safe-stable-stringify"), 1);
47049
+ var import_safe_stable_stringify8 = __toESM(require("safe-stable-stringify"), 1);
47046
47050
  var DEFAULT_CLASSIFIER_PROFILE_RESPONSE_TIMEOUT_MS = 500;
47047
47051
  var DEFAULT_CLASSIFIER_PROFILE_FAILURE_THRESHOLD = 3;
47048
47052
  var DEFAULT_CLASSIFIER_PROFILE_FAILURE_WINDOW_MS = 3e5;
@@ -47179,7 +47183,7 @@ function resolveClassifierProfile(data, inputs, context) {
47179
47183
  });
47180
47184
  }
47181
47185
  function classifierProfileHealthIdentity(profile, projectId, fallbackNodeId) {
47182
- const hash = (value) => `sha256:${import_crypto_js4.default.SHA256((0, import_safe_stable_stringify7.default)(value) ?? "").toString(import_crypto_js4.default.enc.Hex)}`;
47186
+ const hash = (value) => `sha256:${import_crypto_js4.default.SHA256((0, import_safe_stable_stringify8.default)(value) ?? "").toString(import_crypto_js4.default.enc.Hex)}`;
47183
47187
  const configurationFingerprint = hash({
47184
47188
  provider: profile.configuration.provider,
47185
47189
  model: profile.configuration.model,
@@ -48839,7 +48843,7 @@ registerIntegration("embeddingGenerator", "openai", (context) => new OpenAIEmbed
48839
48843
 
48840
48844
  // src/integrations/ManagedKnowledgeStore.ts
48841
48845
  var import_crypto_js5 = __toESM(require("crypto-js"), 1);
48842
- var import_safe_stable_stringify8 = __toESM(require("safe-stable-stringify"), 1);
48846
+ var import_safe_stable_stringify9 = __toESM(require("safe-stable-stringify"), 1);
48843
48847
  var MANAGED_SCHEMA_VERSION = "1";
48844
48848
  var CHUNKER_VERSION = "1";
48845
48849
  var ManagedKnowledgeStore = class {
@@ -49141,7 +49145,7 @@ async function waitForPromiseOrAbort(promise, signal) {
49141
49145
  });
49142
49146
  }
49143
49147
  function createSourceVersion(documents, metadata, chunking) {
49144
- const canonical = (0, import_safe_stable_stringify8.default)({
49148
+ const canonical = (0, import_safe_stable_stringify9.default)({
49145
49149
  schemaVersion: MANAGED_SCHEMA_VERSION,
49146
49150
  chunkerVersion: CHUNKER_VERSION,
49147
49151
  documents,