@digipair/skill-vespa 0.31.3 → 0.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.cjs.js CHANGED
@@ -63882,14 +63882,14 @@ function indent(str, spaces) {
63882
63882
  var match = parseIdentifier(input, i1, namePart) || namePart && parseAdditionalSymbol(input, i1) || maybeSpace && parseSpaces(input, i1);
63883
63883
  // match is required
63884
63884
  if (!match) {
63885
- return tokens = tokens1, nextMatch = nextMatch1, i = i1, {
63885
+ return i = i1, tokens = tokens1, nextMatch = nextMatch1, {
63886
63886
  v: nextMatch1
63887
63887
  };
63888
63888
  }
63889
63889
  var token = match.token, offset = match.offset;
63890
63890
  i1 += offset;
63891
63891
  if (token === " ") {
63892
- return tokens = tokens1, nextMatch = nextMatch1, i = i1, "continue";
63892
+ return i = i1, tokens = tokens1, nextMatch = nextMatch1, "continue";
63893
63893
  }
63894
63894
  tokens1 = _to_consumable_array$1(tokens1).concat([
63895
63895
  token
@@ -63908,7 +63908,7 @@ function indent(str, spaces) {
63908
63908
  if (contextKeys.some(function(el) {
63909
63909
  return el.startsWith(name);
63910
63910
  })) {
63911
- return tokens = tokens1, nextMatch = nextMatch1, i = i1, "continue";
63911
+ return i = i1, tokens = tokens1, nextMatch = nextMatch1, "continue";
63912
63912
  }
63913
63913
  if (dateTimeIdentifiers.some(function(el) {
63914
63914
  return el === name;
@@ -63927,9 +63927,9 @@ function indent(str, spaces) {
63927
63927
  if (dateTimeIdentifiers.some(function(el) {
63928
63928
  return el.startsWith(name);
63929
63929
  })) {
63930
- return tokens = tokens1, nextMatch = nextMatch1, i = i1, "continue";
63930
+ return i = i1, tokens = tokens1, nextMatch = nextMatch1, "continue";
63931
63931
  }
63932
- return tokens = tokens1, nextMatch = nextMatch1, i = i1, {
63932
+ return i = i1, tokens = tokens1, nextMatch = nextMatch1, {
63933
63933
  v: nextMatch1
63934
63934
  };
63935
63935
  };
@@ -67795,7 +67795,8 @@ const executePins = async (settingsOrigin, context = {})=>{
67795
67795
  if (typeof ((_settings_conditions1 = settings.conditions) == null ? void 0 : _settings_conditions1.if) !== 'undefined' && !settings.conditions.if) {
67796
67796
  throw 'DIGIPAIR_CONDITIONS_IF_FALSE';
67797
67797
  }
67798
- const version = context.config.VERSIONS[settings.library] || 'latest';
67798
+ const config = context.config || {};
67799
+ const version = (config.VERSIONS || {})[settings.library] || 'latest';
67799
67800
  const library = _config.LIBRARIES[settings.library] || (typeof window === 'undefined' ? require(settings.library) : await (function (t) { return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(t)); }); })(isRemoteVersion.test(version) ? `${version}` : `${_config.BASE_URL}/${settings.library}@${version}/index.esm.js`));
67800
67801
  const pins = library == null ? void 0 : library[settings.element];
67801
67802
  if (!pins) {
@@ -68009,7 +68010,8 @@ let VespaService = class VespaService {
68009
68010
  const { embeddings = context.privates.MODEL_EMBEDDINGS, baseUrl = (_context_privates_VESPA_SERVER = context.privates.VESPA_SERVER) != null ? _context_privates_VESPA_SERVER : VESPA_SERVER, namespace = (_ref = (_context_privates_VESPA_NAMESPACE = context.privates.VESPA_NAMESPACE) != null ? _context_privates_VESPA_NAMESPACE : process.env['VESPA_NAMESPACE']) != null ? _ref : 'Digipair_default', collection = 'knowledge', documents } = params;
68010
68011
  const modelEmbeddings = await executePinsList(embeddings, context);
68011
68012
  const results = await this.prepareDocuments(documents);
68012
- return await this.pushDocuments(modelEmbeddings, baseUrl, namespace, collection, results);
68013
+ await this.pushDocuments(modelEmbeddings, baseUrl, namespace, collection, results);
68014
+ return results.filter(({ is_parent })=>is_parent).map(({ uuid })=>uuid);
68013
68015
  }
68014
68016
  async remove(params, _pinsSettingsList, context) {
68015
68017
  var _context_privates_VESPA_SERVER, _context_privates_VESPA_NAMESPACE, _ref;
package/index.esm.js CHANGED
@@ -63860,14 +63860,14 @@ function indent(str, spaces) {
63860
63860
  var match = parseIdentifier(input, i1, namePart) || namePart && parseAdditionalSymbol(input, i1) || maybeSpace && parseSpaces(input, i1);
63861
63861
  // match is required
63862
63862
  if (!match) {
63863
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, {
63863
+ return tokens = tokens1, nextMatch = nextMatch1, i = i1, {
63864
63864
  v: nextMatch1
63865
63865
  };
63866
63866
  }
63867
63867
  var token = match.token, offset = match.offset;
63868
63868
  i1 += offset;
63869
63869
  if (token === " ") {
63870
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, "continue";
63870
+ return tokens = tokens1, nextMatch = nextMatch1, i = i1, "continue";
63871
63871
  }
63872
63872
  tokens1 = _to_consumable_array$1(tokens1).concat([
63873
63873
  token
@@ -63886,7 +63886,7 @@ function indent(str, spaces) {
63886
63886
  if (contextKeys.some(function(el) {
63887
63887
  return el.startsWith(name);
63888
63888
  })) {
63889
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, "continue";
63889
+ return tokens = tokens1, nextMatch = nextMatch1, i = i1, "continue";
63890
63890
  }
63891
63891
  if (dateTimeIdentifiers.some(function(el) {
63892
63892
  return el === name;
@@ -63905,9 +63905,9 @@ function indent(str, spaces) {
63905
63905
  if (dateTimeIdentifiers.some(function(el) {
63906
63906
  return el.startsWith(name);
63907
63907
  })) {
63908
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, "continue";
63908
+ return tokens = tokens1, nextMatch = nextMatch1, i = i1, "continue";
63909
63909
  }
63910
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, {
63910
+ return tokens = tokens1, nextMatch = nextMatch1, i = i1, {
63911
63911
  v: nextMatch1
63912
63912
  };
63913
63913
  };
@@ -67773,7 +67773,8 @@ const executePins = async (settingsOrigin, context = {})=>{
67773
67773
  if (typeof ((_settings_conditions1 = settings.conditions) == null ? void 0 : _settings_conditions1.if) !== 'undefined' && !settings.conditions.if) {
67774
67774
  throw 'DIGIPAIR_CONDITIONS_IF_FALSE';
67775
67775
  }
67776
- const version = context.config.VERSIONS[settings.library] || 'latest';
67776
+ const config = context.config || {};
67777
+ const version = (config.VERSIONS || {})[settings.library] || 'latest';
67777
67778
  const library = _config.LIBRARIES[settings.library] || (typeof window === 'undefined' ? require(settings.library) : await import(isRemoteVersion.test(version) ? `${version}` : `${_config.BASE_URL}/${settings.library}@${version}/index.esm.js`));
67778
67779
  const pins = library == null ? void 0 : library[settings.element];
67779
67780
  if (!pins) {
@@ -67987,7 +67988,8 @@ let VespaService = class VespaService {
67987
67988
  const { embeddings = context.privates.MODEL_EMBEDDINGS, baseUrl = (_context_privates_VESPA_SERVER = context.privates.VESPA_SERVER) != null ? _context_privates_VESPA_SERVER : VESPA_SERVER, namespace = (_ref = (_context_privates_VESPA_NAMESPACE = context.privates.VESPA_NAMESPACE) != null ? _context_privates_VESPA_NAMESPACE : process.env['VESPA_NAMESPACE']) != null ? _ref : 'Digipair_default', collection = 'knowledge', documents } = params;
67988
67989
  const modelEmbeddings = await executePinsList(embeddings, context);
67989
67990
  const results = await this.prepareDocuments(documents);
67990
- return await this.pushDocuments(modelEmbeddings, baseUrl, namespace, collection, results);
67991
+ await this.pushDocuments(modelEmbeddings, baseUrl, namespace, collection, results);
67992
+ return results.filter(({ is_parent })=>is_parent).map(({ uuid })=>uuid);
67991
67993
  }
67992
67994
  async remove(params, _pinsSettingsList, context) {
67993
67995
  var _context_privates_VESPA_SERVER, _context_privates_VESPA_NAMESPACE, _ref;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digipair/skill-vespa",
3
- "version": "0.31.3",
3
+ "version": "0.32.0",
4
4
  "dependencies": {},
5
5
  "main": "./index.cjs.js",
6
6
  "module": "./index.esm.js"