@promptbook/remote-client 0.65.0-2 → 0.65.0-4

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 (25) hide show
  1. package/esm/index.es.js +19 -9
  2. package/esm/index.es.js.map +1 -1
  3. package/esm/typings/src/_packages/anthropic-claude.index.d.ts +6 -0
  4. package/esm/typings/src/_packages/core.index.d.ts +2 -0
  5. package/esm/typings/src/_packages/node.index.d.ts +0 -2
  6. package/esm/typings/src/_packages/remote-client.index.d.ts +2 -2
  7. package/esm/typings/src/_packages/types.index.d.ts +16 -2
  8. package/esm/typings/src/llm-providers/_common/config.d.ts +3 -3
  9. package/esm/typings/src/llm-providers/anthropic-claude/AnthropicClaudeExecutionTools.d.ts +5 -3
  10. package/esm/typings/src/llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions.d.ts +23 -2
  11. package/esm/typings/src/llm-providers/anthropic-claude/createAnthropicClaudeExecutionTools.d.ts +13 -0
  12. package/esm/typings/src/llm-providers/anthropic-claude/playground/playground.d.ts +1 -1
  13. package/esm/typings/src/llm-providers/remote/RemoteLlmExecutionTools.d.ts +3 -2
  14. package/esm/typings/src/llm-providers/remote/interfaces/Promptbook_Server_Error.d.ts +2 -2
  15. package/esm/typings/src/llm-providers/remote/interfaces/Promptbook_Server_Progress.d.ts +2 -2
  16. package/esm/typings/src/llm-providers/remote/interfaces/Promptbook_Server_Request.d.ts +14 -2
  17. package/esm/typings/src/llm-providers/remote/interfaces/RemoteLlmExecutionToolsOptions.d.ts +49 -0
  18. package/esm/typings/src/llm-providers/remote/interfaces/RemoteServerOptions.d.ts +23 -2
  19. package/esm/typings/src/llm-providers/remote/playground/playground.d.ts +2 -0
  20. package/esm/typings/src/llm-providers/remote/startRemoteServer.d.ts +2 -1
  21. package/esm/typings/src/types/typeAliases.d.ts +6 -0
  22. package/package.json +2 -2
  23. package/umd/index.umd.js +19 -9
  24. package/umd/index.umd.js.map +1 -1
  25. package/esm/typings/src/llm-providers/remote/RemoteLlmExecutionToolsOptions.d.ts +0 -26
package/esm/index.es.js CHANGED
@@ -4,7 +4,7 @@ import { io } from 'socket.io-client';
4
4
  /**
5
5
  * The version of the Promptbook library
6
6
  */
7
- var PROMPTBOOK_VERSION = '0.65.0-1';
7
+ var PROMPTBOOK_VERSION = '0.65.0-3';
8
8
  // TODO: !!!! List here all the versions and annotate + put into script
9
9
 
10
10
  /*! *****************************************************************************
@@ -126,7 +126,7 @@ var RemoteLlmExecutionTools = /** @class */ (function () {
126
126
  RemoteLlmExecutionTools.prototype.makeConnection = function () {
127
127
  var _this = this;
128
128
  return new Promise(function (resolve, reject) {
129
- var socket = io(_this.options.remoteUrl.href, {
129
+ var socket = io(_this.options.remoteUrl, {
130
130
  path: _this.options.path,
131
131
  // path: `${this.remoteUrl.pathname}/socket.io`,
132
132
  transports: [/*'websocket', <- TODO: [🌬] Make websocket transport work */ 'polling'],
@@ -136,7 +136,7 @@ var RemoteLlmExecutionTools = /** @class */ (function () {
136
136
  resolve(socket);
137
137
  });
138
138
  setTimeout(function () {
139
- reject(new Error("Timeout while connecting to ".concat(_this.options.remoteUrl.href)));
139
+ reject(new Error("Timeout while connecting to ".concat(_this.options.remoteUrl)));
140
140
  }, 60000 /* <- TODO: Timeout to config */);
141
141
  });
142
142
  };
@@ -179,11 +179,20 @@ var RemoteLlmExecutionTools = /** @class */ (function () {
179
179
  case 0: return [4 /*yield*/, this.makeConnection()];
180
180
  case 1:
181
181
  socket = _a.sent();
182
- socket.emit('request', {
183
- clientId: this.options.clientId,
184
- prompt: prompt,
185
- // <- TODO: [🛫] `prompt` is NOT fully serializable as JSON, it contains functions which are not serializable
186
- });
182
+ if (this.options.isAnonymous) {
183
+ socket.emit('request', {
184
+ llmToolsConfiguration: this.options.llmToolsConfiguration,
185
+ prompt: prompt,
186
+ // <- TODO: [🛫] `prompt` is NOT fully serializable as JSON, it contains functions which are not serializable
187
+ });
188
+ }
189
+ else {
190
+ socket.emit('request', {
191
+ clientId: this.options.clientId,
192
+ prompt: prompt,
193
+ // <- TODO: [🛫] `prompt` is NOT fully serializable as JSON, it contains functions which are not serializable
194
+ });
195
+ }
187
196
  return [4 /*yield*/, new Promise(function (resolve, reject) {
188
197
  socket.on('response', function (response) {
189
198
  resolve(response.promptResult);
@@ -217,10 +226,11 @@ var RemoteLlmExecutionTools = /** @class */ (function () {
217
226
  return RemoteLlmExecutionTools;
218
227
  }());
219
228
  /**
229
+ * TODO: [🍜] !!!!!! Default remote remoteUrl and path for anonymous server
220
230
  * TODO: [🍓] Allow to list compatible models with each variant
221
231
  * TODO: [🗯] RemoteLlmExecutionTools should extend Destroyable and implement IDestroyable
222
- * TODO: [🍜] Add anonymous option
223
232
  * TODO: [🧠][🌰] Allow to pass `title` for tracking purposes
233
+ * TODO: [🧠] Maybe remove `@promptbook/remote-client` and just use `@promptbook/core`
224
234
  */
225
235
 
226
236
  export { PROMPTBOOK_VERSION, RemoteLlmExecutionTools };
@@ -1 +1 @@
1
- {"version":3,"file":"index.es.js","sources":["../../../../src/version.ts","../../../node_modules/tslib/tslib.es6.js","../../../../src/errors/PipelineExecutionError.ts","../../../../src/llm-providers/remote/RemoteLlmExecutionTools.ts"],"sourcesContent":[null,"/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n",null,null],"names":[],"mappings":";;AAAA;AAIA;;;IAGa,kBAAkB,GAA8B,WAAW;AAGxE;;ACVA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,aAAa,GAAG,SAAS,CAAC,EAAE,CAAC,EAAE;AACnC,IAAI,aAAa,GAAG,MAAM,CAAC,cAAc;AACzC,SAAS,EAAE,SAAS,EAAE,EAAE,EAAE,YAAY,KAAK,IAAI,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,SAAS,GAAG,CAAC,CAAC,EAAE,CAAC;AACpF,QAAQ,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,KAAK,IAAI,CAAC,IAAI,CAAC,EAAE,IAAI,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;AAC1G,IAAI,OAAO,aAAa,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAC/B,CAAC,CAAC;AACF;AACO,SAAS,SAAS,CAAC,CAAC,EAAE,CAAC,EAAE;AAChC,IAAI,IAAI,OAAO,CAAC,KAAK,UAAU,IAAI,CAAC,KAAK,IAAI;AAC7C,QAAQ,MAAM,IAAI,SAAS,CAAC,sBAAsB,GAAG,MAAM,CAAC,CAAC,CAAC,GAAG,+BAA+B,CAAC,CAAC;AAClG,IAAI,aAAa,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AACxB,IAAI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ACvD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;oCAC/B,MAAM,CAAC,UAAU,EAAE,CAAC;iCACvB,CAAC,CAAC;gCACH,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,UAAC,KAA8B;oCAC9C,MAAM,CAAC,IAAI,sBAAsB,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC;oCACvD,MAAM,CAAC,UAAU,EAAE,CAAC;iCACvB,CAAC,CAAC;6BACN,CAAC,EAAA;;wBATI,YAAY,GAAG,SASnB;wBAEF,MAAM,CAAC,UAAU,EAAE,CAAC;wBAEpB,sBAAO,YAAY,EAAC;;;;KACvB;;;;IAKY,4CAAU,GAAvB;;;gBACI,sBAAO;;qBAEN,EAAC;;;KACL;IACL,8BAAC;AAAD,CAAC,IAAA;AAED;;;;;;;;;"}
1
+ {"version":3,"file":"index.es.js","sources":["../../../../src/version.ts","../../../node_modules/tslib/tslib.es6.js","../../../../src/errors/PipelineExecutionError.ts","../../../../src/llm-providers/remote/RemoteLlmExecutionTools.ts"],"sourcesContent":[null,"/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n",null,null],"names":[],"mappings":";;AAAA;AAIA;;;IAGa,kBAAkB,GAA8B,WAAW;AAGxE;;ACVA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,aAAa,GAAG,SAAS,CAAC,EAAE,CAAC,EAAE;AACnC,IAAI,aAAa,GAAG,MAAM,CAAC,cAAc;AACzC,SAAS,EAAE,SAAS,EAAE,EAAE,EAAE,YAAY,KAAK,IAAI,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,SAAS,GAAG,CAAC,CAAC,EAAE,CAAC;AACpF,QAAQ,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,KAAK,IAAI,CAAC,IAAI,CAAC,EAAE,IAAI,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;AAC1G,IAAI,OAAO,aAAa,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAC/B,CAAC,CAAC;AACF;AACO,SAAS,SAAS,CAAC,CAAC,EAAE,CAAC,EAAE;AAChC,IAAI,IAAI,OAAO,CAAC,KAAK,UAAU,IAAI,CAAC,KAAK,IAAI;AAC7C,QAAQ,MAAM,IAAI,SAAS,CAAC,sBAAsB,GAAG,MAAM,CAAC,CAAC,CAAC,GAAG,+BAA+B,CAAC,CAAC;AAClG,IAAI,aAAa,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AACxB,IAAI,SAAS,EAAE,GAAG,EAAE,IAAI,CAAC,WAAW,GAAG,CAAC,CAAC,EAAE;AAC3C,IAAI,CAAC,CAAC,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,OAAO,CAAe,UAAC,OAAO,EAAE,MAAM;gCACjE,MAAM,CAAC,EAAE,CAAC,UAAU,EAAE,UAAC,QAAoC;oCACvD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;oCAC/B,MAAM,CAAC,UAAU,EAAE,CAAC;iCACvB,CAAC,CAAC;gCACH,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,UAAC,KAA8B;oCAC9C,MAAM,CAAC,IAAI,sBAAsB,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC;oCACvD,MAAM,CAAC,UAAU,EAAE,CAAC;iCACvB,CAAC,CAAC;6BACN,CAAC,EAAA;;wBATI,YAAY,GAAG,SASnB;wBAEF,MAAM,CAAC,UAAU,EAAE,CAAC;wBAEpB,sBAAO,YAAY,EAAC;;;;KACvB;;;;IAKY,4CAAU,GAAvB;;;gBACI,sBAAO;;qBAEN,EAAC;;;KACL;IACL,8BAAC;AAAD,CAAC,IAAA;AAED;;;;;;;;;;"}
@@ -2,7 +2,13 @@ import { PROMPTBOOK_VERSION } from '../version';
2
2
  import { ANTHROPIC_CLAUDE_MODELS } from '../llm-providers/anthropic-claude/anthropic-claude-models';
3
3
  import { AnthropicClaudeExecutionTools } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionTools';
4
4
  import type { AnthropicClaudeExecutionToolsOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
5
+ import type { AnthropicClaudeExecutionToolsDirectOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
6
+ import type { AnthropicClaudeExecutionToolsProxiedOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
7
+ import { createAnthropicClaudeExecutionTools } from '../llm-providers/anthropic-claude/createAnthropicClaudeExecutionTools';
5
8
  export { PROMPTBOOK_VERSION };
6
9
  export { ANTHROPIC_CLAUDE_MODELS };
7
10
  export { AnthropicClaudeExecutionTools };
8
11
  export type { AnthropicClaudeExecutionToolsOptions };
12
+ export type { AnthropicClaudeExecutionToolsDirectOptions };
13
+ export type { AnthropicClaudeExecutionToolsProxiedOptions };
14
+ export { createAnthropicClaudeExecutionTools };
@@ -45,6 +45,7 @@ import { CallbackInterfaceTools } from '../knowledge/dialogs/callback/CallbackIn
45
45
  import type { CallbackInterfaceToolsOptions } from '../knowledge/dialogs/callback/CallbackInterfaceToolsOptions';
46
46
  import { prepareKnowledgePieces } from '../knowledge/prepare-knowledge/_common/prepareKnowledgePieces';
47
47
  import { prepareKnowledgeFromMarkdown } from '../knowledge/prepare-knowledge/markdown/prepareKnowledgeFromMarkdown';
48
+ import { LLM_CONFIGURATION_BOILERPLATES } from '../llm-providers/_common/config';
48
49
  import { createLlmToolsFromConfiguration } from '../llm-providers/_common/createLlmToolsFromConfiguration';
49
50
  import { cacheLlmTools } from '../llm-providers/_common/utils/cache/cacheLlmTools';
50
51
  import { countTotalUsage } from '../llm-providers/_common/utils/count-total-usage/countTotalUsage';
@@ -109,6 +110,7 @@ export { CallbackInterfaceTools };
109
110
  export type { CallbackInterfaceToolsOptions };
110
111
  export { prepareKnowledgePieces };
111
112
  export { prepareKnowledgeFromMarkdown };
113
+ export { LLM_CONFIGURATION_BOILERPLATES };
112
114
  export { createLlmToolsFromConfiguration };
113
115
  export { cacheLlmTools };
114
116
  export { countTotalUsage };
@@ -1,12 +1,10 @@
1
1
  import { PROMPTBOOK_VERSION } from '../version';
2
2
  import { createCollectionFromDirectory } from '../collection/constructors/createCollectionFromDirectory';
3
- import { LLM_CONFIGURATION_BOILERPLATES } from '../llm-providers/_common/config';
4
3
  import { createLlmToolsFromConfigurationFromEnv } from '../llm-providers/_common/createLlmToolsFromConfigurationFromEnv';
5
4
  import { createLlmToolsFromEnv } from '../llm-providers/_common/createLlmToolsFromEnv';
6
5
  import { FilesStorage } from '../storage/files-storage/FilesStorage';
7
6
  export { PROMPTBOOK_VERSION };
8
7
  export { createCollectionFromDirectory };
9
- export { LLM_CONFIGURATION_BOILERPLATES };
10
8
  export { createLlmToolsFromConfigurationFromEnv };
11
9
  export { createLlmToolsFromEnv };
12
10
  export { FilesStorage };
@@ -1,8 +1,8 @@
1
1
  import { PROMPTBOOK_VERSION } from '../version';
2
+ import type { RemoteLlmExecutionToolsOptions } from '../llm-providers/remote/interfaces/RemoteLlmExecutionToolsOptions';
2
3
  import type { RemoteServerOptions } from '../llm-providers/remote/interfaces/RemoteServerOptions';
3
4
  import { RemoteLlmExecutionTools } from '../llm-providers/remote/RemoteLlmExecutionTools';
4
- import type { RemoteLlmExecutionToolsOptions } from '../llm-providers/remote/RemoteLlmExecutionToolsOptions';
5
5
  export { PROMPTBOOK_VERSION };
6
+ export type { RemoteLlmExecutionToolsOptions };
6
7
  export type { RemoteServerOptions };
7
8
  export { RemoteLlmExecutionTools };
8
- export type { RemoteLlmExecutionToolsOptions };
@@ -35,6 +35,8 @@ import type { CacheItem } from '../llm-providers/_common/utils/cache/CacheItem';
35
35
  import type { CacheLlmToolsOptions } from '../llm-providers/_common/utils/cache/CacheLlmToolsOptions';
36
36
  import type { LlmExecutionToolsWithTotalUsage } from '../llm-providers/_common/utils/count-total-usage/LlmExecutionToolsWithTotalUsage';
37
37
  import type { AnthropicClaudeExecutionToolsOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
38
+ import type { AnthropicClaudeExecutionToolsDirectOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
39
+ import type { AnthropicClaudeExecutionToolsProxiedOptions } from '../llm-providers/anthropic-claude/AnthropicClaudeExecutionToolsOptions';
38
40
  import type { AzureOpenAiExecutionToolsOptions } from '../llm-providers/azure-openai/AzureOpenAiExecutionToolsOptions';
39
41
  import type { LangtailExecutionToolsOptions } from '../llm-providers/langtail/LangtailExecutionToolsOptions';
40
42
  import type { MultipleLlmExecutionTools } from '../llm-providers/multiple/MultipleLlmExecutionTools';
@@ -42,9 +44,13 @@ import type { OpenAiExecutionToolsOptions } from '../llm-providers/openai/OpenAi
42
44
  import type { Promptbook_Server_Error } from '../llm-providers/remote/interfaces/Promptbook_Server_Error';
43
45
  import type { Promptbook_Server_Progress } from '../llm-providers/remote/interfaces/Promptbook_Server_Progress';
44
46
  import type { Promptbook_Server_Request } from '../llm-providers/remote/interfaces/Promptbook_Server_Request';
47
+ import type { Promptbook_Server_CollectionRequest } from '../llm-providers/remote/interfaces/Promptbook_Server_Request';
48
+ import type { Promptbook_Server_AnonymousRequest } from '../llm-providers/remote/interfaces/Promptbook_Server_Request';
45
49
  import type { Promptbook_Server_Response } from '../llm-providers/remote/interfaces/Promptbook_Server_Response';
50
+ import type { RemoteLlmExecutionToolsOptions } from '../llm-providers/remote/interfaces/RemoteLlmExecutionToolsOptions';
46
51
  import type { RemoteServerOptions } from '../llm-providers/remote/interfaces/RemoteServerOptions';
47
- import type { RemoteLlmExecutionToolsOptions } from '../llm-providers/remote/RemoteLlmExecutionToolsOptions';
52
+ import type { AnonymousRemoteServerOptions } from '../llm-providers/remote/interfaces/RemoteServerOptions';
53
+ import type { CollectionRemoteServerOptions } from '../llm-providers/remote/interfaces/RemoteServerOptions';
48
54
  import type { PrepareOptions } from '../prepare/PrepareOptions';
49
55
  import type { JavascriptExecutionToolsOptions } from '../scripting/javascript/JavascriptExecutionToolsOptions';
50
56
  import type { PostprocessingFunction } from '../scripting/javascript/JavascriptExecutionToolsOptions';
@@ -126,6 +132,7 @@ import type { string_css_property } from '../types/typeAliases';
126
132
  import type { string_css_value } from '../types/typeAliases';
127
133
  import type { string_css_selector } from '../types/typeAliases';
128
134
  import type { string_url } from '../types/typeAliases';
135
+ import type { string_base_url } from '../types/typeAliases';
129
136
  import type { string_pipeline_url } from '../types/typeAliases';
130
137
  import type { string_pipeline_url_with_hashtemplate } from '../types/typeAliases';
131
138
  import type { string_data_url } from '../types/typeAliases';
@@ -243,6 +250,8 @@ export type { CacheItem };
243
250
  export type { CacheLlmToolsOptions };
244
251
  export type { LlmExecutionToolsWithTotalUsage };
245
252
  export type { AnthropicClaudeExecutionToolsOptions };
253
+ export type { AnthropicClaudeExecutionToolsDirectOptions };
254
+ export type { AnthropicClaudeExecutionToolsProxiedOptions };
246
255
  export type { AzureOpenAiExecutionToolsOptions };
247
256
  export type { LangtailExecutionToolsOptions };
248
257
  export type { MultipleLlmExecutionTools };
@@ -250,9 +259,13 @@ export type { OpenAiExecutionToolsOptions };
250
259
  export type { Promptbook_Server_Error };
251
260
  export type { Promptbook_Server_Progress };
252
261
  export type { Promptbook_Server_Request };
262
+ export type { Promptbook_Server_CollectionRequest };
263
+ export type { Promptbook_Server_AnonymousRequest };
253
264
  export type { Promptbook_Server_Response };
254
- export type { RemoteServerOptions };
255
265
  export type { RemoteLlmExecutionToolsOptions };
266
+ export type { RemoteServerOptions };
267
+ export type { AnonymousRemoteServerOptions };
268
+ export type { CollectionRemoteServerOptions };
256
269
  export type { PrepareOptions };
257
270
  export type { JavascriptExecutionToolsOptions };
258
271
  export type { PostprocessingFunction };
@@ -334,6 +347,7 @@ export type { string_css_property };
334
347
  export type { string_css_value };
335
348
  export type { string_css_selector };
336
349
  export type { string_url };
350
+ export type { string_base_url };
337
351
  export type { string_pipeline_url };
338
352
  export type { string_pipeline_url_with_hashtemplate };
339
353
  export type { string_data_url };
@@ -1,14 +1,14 @@
1
- import type { TODO_any } from '../../utils/organization/TODO_any';
2
1
  import type { LlmExecutionTools } from '../../execution/LlmExecutionTools';
2
+ import type { TODO_any } from '../../utils/organization/TODO_any';
3
3
  import type { LlmToolsConfiguration } from './LlmToolsConfiguration';
4
4
  /**
5
- * @public exported from `@promptbook/node`
5
+ * @public exported from `@promptbook/core`
6
6
  */
7
7
  export declare const LLM_CONFIGURATION_BOILERPLATES: LlmToolsConfiguration;
8
8
  /**
9
9
  * @private internal type for `createLlmToolsFromConfiguration`
10
10
  */
11
- export declare const EXECUTION_TOOLS_CLASSES: Record<`get${string}`, (options: TODO_any) => LlmExecutionTools>;
11
+ export declare const EXECUTION_TOOLS_CLASSES: Record<`create${string}`, (options: TODO_any) => LlmExecutionTools>;
12
12
  /**
13
13
  * TODO: [🧠] Better file name than `config.ts` + maybe move to two separate files
14
14
  * TODO: [🧠][🎌] Adding this should be responsibility of each provider package NOT this one central place
@@ -5,11 +5,12 @@ import type { Prompt } from '../../types/Prompt';
5
5
  import type { string_markdown } from '../../types/typeAliases';
6
6
  import type { string_markdown_text } from '../../types/typeAliases';
7
7
  import type { string_title } from '../../types/typeAliases';
8
- import type { AnthropicClaudeExecutionToolsOptions } from './AnthropicClaudeExecutionToolsOptions';
8
+ import type { AnthropicClaudeExecutionToolsDirectOptions } from './AnthropicClaudeExecutionToolsOptions';
9
9
  /**
10
10
  * Execution Tools for calling Anthropic Claude API.
11
11
  *
12
12
  * @public exported from `@promptbook/anthropic-claude`
13
+ * @deprecated use `createAnthropicClaudeExecutionTools` instead
13
14
  */
14
15
  export declare class AnthropicClaudeExecutionTools implements LlmExecutionTools {
15
16
  private readonly options;
@@ -22,7 +23,7 @@ export declare class AnthropicClaudeExecutionTools implements LlmExecutionTools
22
23
  *
23
24
  * @param options which are relevant are directly passed to the Anthropic Claude client
24
25
  */
25
- constructor(options?: AnthropicClaudeExecutionToolsOptions);
26
+ constructor(options?: AnthropicClaudeExecutionToolsDirectOptions);
26
27
  get title(): string_title & string_markdown_text;
27
28
  get description(): string_markdown;
28
29
  /**
@@ -48,6 +49,7 @@ export declare class AnthropicClaudeExecutionTools implements LlmExecutionTools
48
49
  * TODO: Maybe Create some common util for callChatModel and callCompletionModel
49
50
  * TODO: Maybe make custom OpenaiError
50
51
  * TODO: [🧠][🈁] Maybe use `isDeterministic` from options
51
- * TODO: [🍜] Auto use anonymous server in browser
52
+ * TODO: [🍜] !!!!!! Auto use anonymous server in browser
52
53
  * TODO: [🧠][🌰] Allow to pass `title` for tracking purposes
54
+ * TODO: [📅] Maybe instead of `RemoteLlmExecutionToolsOptions` use `proxyWithAnonymousRemoteServer` (if implemented)
53
55
  */
@@ -1,12 +1,33 @@
1
1
  import type { ClientOptions } from '@anthropic-ai/sdk';
2
2
  import type { CommonExecutionToolsOptions } from '../../execution/CommonExecutionToolsOptions';
3
+ import type { RemoteLlmExecutionToolsOptions } from '../remote/interfaces/RemoteLlmExecutionToolsOptions';
3
4
  /**
4
5
  * Options for `AnthropicClaudeExecutionTools`
5
6
  *
6
7
  * This extends Anthropic's `ClientOptions` with are directly passed to the Anthropic client.
7
8
  * @public exported from `@promptbook/anthropic-claude`
8
9
  */
9
- export type AnthropicClaudeExecutionToolsOptions = CommonExecutionToolsOptions & ClientOptions;
10
+ export type AnthropicClaudeExecutionToolsOptions = AnthropicClaudeExecutionToolsDirectOptions | AnthropicClaudeExecutionToolsProxiedOptions;
10
11
  /**
11
- * TODO: [🍜] Auto add WebGPT / Promptbook.studio anonymous server in browser
12
+ * Options for directly used `AnthropicClaudeExecutionTools`
13
+ *
14
+ * This extends Anthropic's `ClientOptions` with are directly passed to the Anthropic client.
15
+ * @public exported from `@promptbook/anthropic-claude`
16
+ */
17
+ export type AnthropicClaudeExecutionToolsDirectOptions = CommonExecutionToolsOptions & ClientOptions & {
18
+ isProxied?: false;
19
+ };
20
+ /**
21
+ * Options for proxied `AnthropicClaudeExecutionTools`
22
+ *
23
+ * This extends Anthropic's `ClientOptions` with are directly passed to the Anthropic client.
24
+ * @public exported from `@promptbook/anthropic-claude`
25
+ */
26
+ export type AnthropicClaudeExecutionToolsProxiedOptions = CommonExecutionToolsOptions & ClientOptions & {
27
+ isProxied: true;
28
+ } & Pick<RemoteLlmExecutionToolsOptions, 'remoteUrl' | 'path'>;
29
+ /**
30
+ * TODO: [🍜] Default remote remoteUrl and path for anonymous server
31
+ * TODO: [🍜] !!!!!! Auto add WebGPT / Promptbook.studio anonymous server in browser
32
+ * TODO: [🧠][🤺] Detecting `user`
12
33
  */
@@ -0,0 +1,13 @@
1
+ import { RemoteLlmExecutionTools } from '../remote/RemoteLlmExecutionTools';
2
+ import { AnthropicClaudeExecutionTools } from './AnthropicClaudeExecutionTools';
3
+ import type { AnthropicClaudeExecutionToolsOptions } from './AnthropicClaudeExecutionToolsOptions';
4
+ /**
5
+ * Execution Tools for calling Anthropic Claude API.
6
+ *
7
+ * @public exported from `@promptbook/anthropic-claude`
8
+ */
9
+ export declare function createAnthropicClaudeExecutionTools(options: AnthropicClaudeExecutionToolsOptions): AnthropicClaudeExecutionTools | RemoteLlmExecutionTools;
10
+ /**
11
+ * TODO: !!!!!! Make this with all LLM providers
12
+ * TODO: !!!!!! Maybe change all `new AnthropicClaudeExecutionTools` -> `createAnthropicClaudeExecutionTools` in manual
13
+ */
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env ts-node
2
2
  export {};
3
3
  /**
4
- * TODO: [🍜] Playground with WebGPT / Promptbook.studio anonymous server
4
+ * TODO: [🍜] !!!!!! Playground with WebGPT / Promptbook.studio anonymous server
5
5
  * TODO: !!! Test here that `systemMessage`, `temperature` and `seed` are working correctly
6
6
  */
@@ -9,7 +9,7 @@ import type { EmbeddingPrompt } from '../../types/Prompt';
9
9
  import type { string_markdown } from '../../types/typeAliases';
10
10
  import type { string_markdown_text } from '../../types/typeAliases';
11
11
  import type { string_title } from '../../types/typeAliases';
12
- import type { RemoteLlmExecutionToolsOptions } from './RemoteLlmExecutionToolsOptions';
12
+ import type { RemoteLlmExecutionToolsOptions } from './interfaces/RemoteLlmExecutionToolsOptions';
13
13
  /**
14
14
  * Remote server is a proxy server that uses its execution tools internally and exposes the executor interface externally.
15
15
  *
@@ -50,8 +50,9 @@ export declare class RemoteLlmExecutionTools implements LlmExecutionTools {
50
50
  listModels(): Promise<Array<AvailableModel>>;
51
51
  }
52
52
  /**
53
+ * TODO: [🍜] !!!!!! Default remote remoteUrl and path for anonymous server
53
54
  * TODO: [🍓] Allow to list compatible models with each variant
54
55
  * TODO: [🗯] RemoteLlmExecutionTools should extend Destroyable and implement IDestroyable
55
- * TODO: [🍜] Add anonymous option
56
56
  * TODO: [🧠][🌰] Allow to pass `title` for tracking purposes
57
+ * TODO: [🧠] Maybe remove `@promptbook/remote-client` and just use `@promptbook/core`
57
58
  */
@@ -3,9 +3,9 @@
3
3
  *
4
4
  * This is sent from server to client when error occurs and stops the process
5
5
  */
6
- export interface Promptbook_Server_Error {
6
+ export type Promptbook_Server_Error = {
7
7
  /**
8
8
  * The error message which caused the error
9
9
  */
10
10
  readonly errorMessage: string;
11
- }
11
+ };
@@ -4,9 +4,9 @@ import type { TaskProgress } from '../../../types/TaskProgress';
4
4
  *
5
5
  * This is sent from server to client arbitrarily and may be sent multiple times
6
6
  */
7
- export interface Promptbook_Server_Progress {
7
+ export type Promptbook_Server_Progress = {
8
8
  /**
9
9
  * The progress of text generation
10
10
  */
11
11
  readonly taskProgress: TaskProgress;
12
- }
12
+ };
@@ -1,11 +1,13 @@
1
1
  import type { Prompt } from '../../../types/Prompt';
2
2
  import type { client_id } from '../../../types/typeAliases';
3
+ import type { LlmToolsConfiguration } from '../../_common/LlmToolsConfiguration';
3
4
  /**
4
5
  * Socket.io progress for remote text generation
5
6
  *
6
7
  * This is a request from client to server
7
8
  */
8
- export interface Promptbook_Server_Request {
9
+ export type Promptbook_Server_Request = Promptbook_Server_CollectionRequest | Promptbook_Server_AnonymousRequest;
10
+ export type Promptbook_Server_CollectionRequest = {
9
11
  /**
10
12
  * Client responsible for the requests
11
13
  */
@@ -14,4 +16,14 @@ export interface Promptbook_Server_Request {
14
16
  * The Prompt to execute
15
17
  */
16
18
  readonly prompt: Prompt;
17
- }
19
+ };
20
+ export type Promptbook_Server_AnonymousRequest = {
21
+ /**
22
+ * Configuration for the LLM tools
23
+ */
24
+ readonly llmToolsConfiguration: LlmToolsConfiguration;
25
+ /**
26
+ * The Prompt to execute
27
+ */
28
+ readonly prompt: Prompt;
29
+ };
@@ -0,0 +1,49 @@
1
+ import type { CommonExecutionToolsOptions } from '../../../execution/CommonExecutionToolsOptions';
2
+ import type { client_id } from '../../../types/typeAliases';
3
+ import type { string_base_url } from '../../../types/typeAliases';
4
+ import type { string_uri } from '../../../types/typeAliases';
5
+ import type { LlmToolsConfiguration } from '../../_common/LlmToolsConfiguration';
6
+ /**
7
+ * Options for `RemoteLlmExecutionTools`
8
+ *
9
+ * @public exported from `@promptbook/remote-client`
10
+ */
11
+ export type RemoteLlmExecutionToolsOptions = CommonExecutionToolsOptions & {
12
+ /**
13
+ * URL of the remote PROMPTBOOK server
14
+ * On this server will be connected to the socket.io server
15
+ */
16
+ readonly remoteUrl: string_base_url;
17
+ /**
18
+ * Path for the Socket.io server to listen
19
+ *
20
+ * @default '/socket.io'
21
+ * @example '/promptbook/socket.io'
22
+ */
23
+ readonly path: string_uri;
24
+ /**
25
+ * Mode of the server to connect to
26
+ */
27
+ isAnonymous: boolean;
28
+ } & ({
29
+ /**
30
+ * Use anonymous server with anonymous mode
31
+ */
32
+ isAnonymous: true;
33
+ /**
34
+ * Configuration for the LLM tools
35
+ */
36
+ readonly llmToolsConfiguration: LlmToolsConfiguration;
37
+ } | {
38
+ /**
39
+ * Use anonymous server with client identification and fixed collection
40
+ */
41
+ isAnonymous: false;
42
+ /**
43
+ * Your client ID
44
+ */
45
+ readonly clientId: client_id;
46
+ });
47
+ /**
48
+ * TODO: [🍜] !!!!!! Default remote remoteUrl and path for anonymous server
49
+ */
@@ -6,6 +6,14 @@ import type { string_uri } from '../../../types/typeAliases';
6
6
  /**
7
7
  * @@@
8
8
  *
9
+ * There are two modes of remote server:
10
+ *
11
+ * 1) **Collection mode** Server will recieve `collection` and execute prompts only from this collection
12
+ * 2) **Anonymous mode** Server will recieve full `LlmToolsConfiguration` (with api keys) and just acts as a proxy
13
+ * In anonymous mode, `collection` will be ignored and any prompt will be executed
14
+ *
15
+ * You can enable both modes at the same time.
16
+ *
9
17
  * @public exported from `@promptbook/remote-client`
10
18
  * @public exported from `@promptbook/remote-server`
11
19
  */
@@ -21,10 +29,22 @@ export type RemoteServerOptions = CommonExecutionToolsOptions & {
21
29
  * @example '/promptbook/socket.io'
22
30
  */
23
31
  readonly path: string_uri;
32
+ } & (AnonymousRemoteServerOptions | CollectionRemoteServerOptions | (AnonymousRemoteServerOptions & CollectionRemoteServerOptions));
33
+ export type AnonymousRemoteServerOptions = {
34
+ /**
35
+ * Enable anonymous mode
36
+ */
37
+ readonly isAnonymousModeAllowed: true;
38
+ };
39
+ export type CollectionRemoteServerOptions = {
40
+ /**
41
+ * Enable collection mode
42
+ */
43
+ readonly isCollectionModeAllowed: true;
24
44
  /**
25
45
  * Promptbook collection to use
26
46
  *
27
- * This is used to check validity of the prompt to prevent DDoS
47
+ * This is used to check validity of the prompt to prevent misuse
28
48
  */
29
49
  readonly collection: PipelineCollection;
30
50
  /**
@@ -33,5 +53,6 @@ export type RemoteServerOptions = CommonExecutionToolsOptions & {
33
53
  createLlmExecutionTools(clientId: client_id): LlmExecutionTools;
34
54
  };
35
55
  /**
36
- * TODO: [🍜] Add anonymous option
56
+ * TODO: Constrain anonymous mode for specific models / providers
57
+ * TODO: [🧠][🤺] Remove `createLlmExecutionTools`, pass just `llmExecutionTools`
37
58
  */
@@ -0,0 +1,2 @@
1
+ #!/usr/bin/env ts-node
2
+ export {};
@@ -11,11 +11,12 @@ import type { RemoteServerOptions } from './interfaces/RemoteServerOptions';
11
11
  */
12
12
  export declare function startRemoteServer(options: RemoteServerOptions): IDestroyable;
13
13
  /**
14
- * TODO: [🍜] Add anonymous option
14
+ * TODO: [🍜] !!!!!! Add anonymous option
15
15
  * TODO: [⚖] Expose the collection to be able to connect to same collection via createCollectionFromUrl
16
16
  * TODO: Handle progress - support streaming
17
17
  * TODO: [🗯] Do not hang up immediately but wait until client closes OR timeout
18
18
  * TODO: [🗯] Timeout on chat to free up resources
19
19
  * TODO: [🃏] Pass here some security token to prevent malitious usage and/or DDoS
20
20
  * TODO: [0] Set unavailable models as undefined in `RemoteLlmExecutionTools` NOT throw error here
21
+ * TODO: Constrain anonymous mode for specific models / providers
21
22
  */
@@ -286,6 +286,12 @@ export type string_css_selector = string;
286
286
  * For example `"https://collboard.com/9SeSQTupmQHwuSrLi"`
287
287
  */
288
288
  export type string_url = string;
289
+ /**
290
+ * Semantic helper
291
+ *
292
+ * For example `"https://collboard.com"`
293
+ */
294
+ export type string_base_url = string;
289
295
  /**
290
296
  * Semantic helper
291
297
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@promptbook/remote-client",
3
- "version": "0.65.0-2",
3
+ "version": "0.65.0-4",
4
4
  "description": "Supercharge your use of large language models",
5
5
  "private": false,
6
6
  "sideEffects": false,
@@ -47,7 +47,7 @@
47
47
  "module": "./esm/index.es.js",
48
48
  "typings": "./esm/typings/src/_packages/remote-client.index.d.ts",
49
49
  "peerDependencies": {
50
- "@promptbook/core": "0.65.0-2"
50
+ "@promptbook/core": "0.65.0-4"
51
51
  },
52
52
  "dependencies": {
53
53
  "socket.io-client": "4.7.2"
package/umd/index.umd.js CHANGED
@@ -8,7 +8,7 @@
8
8
  /**
9
9
  * The version of the Promptbook library
10
10
  */
11
- var PROMPTBOOK_VERSION = '0.65.0-1';
11
+ var PROMPTBOOK_VERSION = '0.65.0-3';
12
12
  // TODO: !!!! List here all the versions and annotate + put into script
13
13
 
14
14
  /*! *****************************************************************************
@@ -130,7 +130,7 @@
130
130
  RemoteLlmExecutionTools.prototype.makeConnection = function () {
131
131
  var _this = this;
132
132
  return new Promise(function (resolve, reject) {
133
- var socket = socket_ioClient.io(_this.options.remoteUrl.href, {
133
+ var socket = socket_ioClient.io(_this.options.remoteUrl, {
134
134
  path: _this.options.path,
135
135
  // path: `${this.remoteUrl.pathname}/socket.io`,
136
136
  transports: [/*'websocket', <- TODO: [🌬] Make websocket transport work */ 'polling'],
@@ -140,7 +140,7 @@
140
140
  resolve(socket);
141
141
  });
142
142
  setTimeout(function () {
143
- reject(new Error("Timeout while connecting to ".concat(_this.options.remoteUrl.href)));
143
+ reject(new Error("Timeout while connecting to ".concat(_this.options.remoteUrl)));
144
144
  }, 60000 /* <- TODO: Timeout to config */);
145
145
  });
146
146
  };
@@ -183,11 +183,20 @@
183
183
  case 0: return [4 /*yield*/, this.makeConnection()];
184
184
  case 1:
185
185
  socket = _a.sent();
186
- socket.emit('request', {
187
- clientId: this.options.clientId,
188
- prompt: prompt,
189
- // <- TODO: [🛫] `prompt` is NOT fully serializable as JSON, it contains functions which are not serializable
190
- });
186
+ if (this.options.isAnonymous) {
187
+ socket.emit('request', {
188
+ llmToolsConfiguration: this.options.llmToolsConfiguration,
189
+ prompt: prompt,
190
+ // <- TODO: [🛫] `prompt` is NOT fully serializable as JSON, it contains functions which are not serializable
191
+ });
192
+ }
193
+ else {
194
+ socket.emit('request', {
195
+ clientId: this.options.clientId,
196
+ prompt: prompt,
197
+ // <- TODO: [🛫] `prompt` is NOT fully serializable as JSON, it contains functions which are not serializable
198
+ });
199
+ }
191
200
  return [4 /*yield*/, new Promise(function (resolve, reject) {
192
201
  socket.on('response', function (response) {
193
202
  resolve(response.promptResult);
@@ -221,10 +230,11 @@
221
230
  return RemoteLlmExecutionTools;
222
231
  }());
223
232
  /**
233
+ * TODO: [🍜] !!!!!! Default remote remoteUrl and path for anonymous server
224
234
  * TODO: [🍓] Allow to list compatible models with each variant
225
235
  * TODO: [🗯] RemoteLlmExecutionTools should extend Destroyable and implement IDestroyable
226
- * TODO: [🍜] Add anonymous option
227
236
  * TODO: [🧠][🌰] Allow to pass `title` for tracking purposes
237
+ * TODO: [🧠] Maybe remove `@promptbook/remote-client` and just use `@promptbook/core`
228
238
  */
229
239
 
230
240
  exports.PROMPTBOOK_VERSION = PROMPTBOOK_VERSION;
@@ -1 +1 @@
1
- {"version":3,"file":"index.umd.js","sources":["../../../../src/version.ts","../../../node_modules/tslib/tslib.es6.js","../../../../src/errors/PipelineExecutionError.ts","../../../../src/llm-providers/remote/RemoteLlmExecutionTools.ts"],"sourcesContent":[null,"/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n",null,null],"names":["io"],"mappings":";;;;;;IAAA;IAIA;;;QAGa,kBAAkB,GAA8B,WAAW;IAGxE;;ICVA;IACA;AACA;IACA;IACA;AACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;AACA;IACA,IAAI,aAAa,GAAG,SAAS,CAAC,EAAE,CAAC,EAAE;IACnC,IAAI,aAAa,GAAG,MAAM,CAAC,cAAc;IACzC,SAAS,EAAE,SAAS,EAAE,EAAE,EAAE,YAAY,KAAK,IAAI,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,SAAS,GAAG,CAAC,CAAC,EAAE,CAAC;IACpF,QAAQ,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,KAAK,IAAI,CAAC,IAAI,CAAC,EAAE,IAAI,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IAC1G,IAAI,OAAO,aA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AOa,iDAAe,GAA7B,UAA8B,MAAc;;;;;gCACzB,qBAAM,IAAI,CAAC,cAAc,EAAE,EAAA;;4BAApC,MAAM,GAAG,SAA2B;4BAC1C,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE;gCACnB,QAAQ,EAAE,IAAI,CAAC,OAAO,CAAC,QAAQ;gCAC/B,MAAM,QAAA;;6BAE2B,CAAC,CAAC;4BAElB,qBAAM,IAAI,OAAO,CAAe,UAAC,OAAO,EAAE,MAAM;oCACjE,MAAM,CAAC,EAAE,CAAC,UAAU,EAAE,UAAC,QAAoC;wCACvD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;wCAC/B,MAAM,CAAC,UAAU,EAAE,CAAC;qCACvB,CAAC,CAAC;oCACH,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,UAAC,KAA8B;wCAC9C,MAAM,CAAC,IAAI,sBAAsB,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC;wCACvD,MAAM,CAAC,UAAU,EAAE,CAAC;qCACvB,CAAC,CAAC;iCACN,CAAC,EAAA;;4BATI,YAAY,GAAG,SASnB;4BAEF,MAAM,CAAC,UAAU,EAAE,CAAC;4BAEpB,sBAAO,YAAY,EAAC;;;;SACvB;;;;QAKY,4CAAU,GAAvB;;;oBACI,sBAAO;;yBAEN,EAAC;;;SACL;QACL,8BAAC;IAAD,CAAC,IAAA;IAED;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.umd.js","sources":["../../../../src/version.ts","../../../node_modules/tslib/tslib.es6.js","../../../../src/errors/PipelineExecutionError.ts","../../../../src/llm-providers/remote/RemoteLlmExecutionTools.ts"],"sourcesContent":[null,"/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || Array.prototype.slice.call(from));\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\n",null,null],"names":["io"],"mappings":";;;;;;IAAA;IAIA;;;QAGa,kBAAkB,GAA8B,WAAW;IAGxE;;ICVA;IACA;AACA;IACA;IACA;AACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;AACA;IACA,IAAI,aAAa,GAAG,SAAS,CAAC,EAAE,CAAC,EAAE;IACnC,IAAI,aAAa,GAAG,MAAM,CAAC,cAAc;IACzC,SAAS,EAAE,SAAS,EAAE,EAAE,EAAE,YAAY,KAAK,IAAI,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,SAAS,GAAG,CAAC,CAAC,EAAE,CAAC;IACpF,QAAQ,UAAU,CAAC,EAAE,CAAC,EAAE,EAAE,KAAK,IAAI,CAAC,IAAI,CAAC,EAAE,IAAI,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IAC1G,IAAI,OAAO,aAAa,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAC/B,CAAC,CAAC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;4BAApC,MAAM,GAAG,SAA2B;4BAE1C,IAAI,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE;gCAC1B,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE;oCACnB,qBAAqB,EAAE,IAAI,CAAC,OAAO,CAAC,qBAAqB;oCACzD,MAAM,QAAA;;iCAE2B,CAAC,CAAC;6BAC1C;iCAAM;gCACH,MAAM,CAAC,IAAI,CAAC,SAAS,EAAE;oCACnB,QAAQ,EAAE,IAAI,CAAC,OAAO,CAAC,QAAQ;oCAC/B,MAAM,QAAA;;iCAE2B,CAAC,CAAC;6BAC1C;4BAEoB,qBAAM,IAAI,OAAO,CAAe,UAAC,OAAO,EAAE,MAAM;oCACjE,MAAM,CAAC,EAAE,CAAC,UAAU,EAAE,UAAC,QAAoC;wCACvD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;wCAC/B,MAAM,CAAC,UAAU,EAAE,CAAC;qCACvB,CAAC,CAAC;oCACH,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,UAAC,KAA8B;wCAC9C,MAAM,CAAC,IAAI,sBAAsB,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC;wCACvD,MAAM,CAAC,UAAU,EAAE,CAAC;qCACvB,CAAC,CAAC;iCACN,CAAC,EAAA;;4BATI,YAAY,GAAG,SASnB;4BAEF,MAAM,CAAC,UAAU,EAAE,CAAC;4BAEpB,sBAAO,YAAY,EAAC;;;;SACvB;;;;QAKY,4CAAU,GAAvB;;;oBACI,sBAAO;;yBAEN,EAAC;;;SACL;QACL,8BAAC;IAAD,CAAC,IAAA;IAED;;;;;;;;;;;;;;;;;"}
@@ -1,26 +0,0 @@
1
- import type { CommonExecutionToolsOptions } from '../../execution/CommonExecutionToolsOptions';
2
- import type { client_id } from '../../types/typeAliases';
3
- import type { string_uri } from '../../types/typeAliases';
4
- /**
5
- * Options for `RemoteLlmExecutionTools`
6
- *
7
- * @public exported from `@promptbook/remote-client`
8
- */
9
- export type RemoteLlmExecutionToolsOptions = CommonExecutionToolsOptions & {
10
- /**
11
- * URL of the remote PROMPTBOOK server
12
- * On this server will be connected to the socket.io server
13
- */
14
- readonly remoteUrl: URL;
15
- /**
16
- * Path for the Socket.io server to listen
17
- *
18
- * @default '/socket.io'
19
- * @example '/promptbook/socket.io'
20
- */
21
- readonly path: string_uri;
22
- /**
23
- * Your client ID
24
- */
25
- readonly clientId: client_id;
26
- };