llmz 0.0.34 → 0.0.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-RANA7NBF.js → chunk-4KXGNHLO.js} +1 -1
- package/dist/{chunk-GXLMCQYF.js → chunk-PUFOVD74.js} +3 -1
- package/dist/{chunk-B742DUFY.cjs → chunk-RD3LPQOW.cjs} +3 -3
- package/dist/{chunk-QR54TZ36.cjs → chunk-WP7SDPJ6.cjs} +3 -1
- package/dist/index.cjs +7 -7
- package/dist/index.js +5 -5
- package/dist/{llmz-HAHKYXAJ.js → llmz-7KVW3LXE.js} +8 -6
- package/dist/{llmz-YU4TWA2R.cjs → llmz-I7RVUI6Q.cjs} +17 -15
- package/dist/llmz.d.ts +2 -1
- package/dist/{tool-ADXBCB4R.js → tool-3YL3EY2R.js} +1 -1
- package/dist/{tool-JYXLFJGQ.cjs → tool-OC3QHJWX.cjs} +2 -2
- package/dist/tool.d.ts +1 -1
- package/package.json +4 -4
|
@@ -415,8 +415,10 @@ var Tool = class _Tool {
|
|
|
415
415
|
*
|
|
416
416
|
* @internal This method is primarily used internally by the LLMz execution engine
|
|
417
417
|
*/
|
|
418
|
-
async execute(
|
|
418
|
+
async execute(rawInput, ctx) {
|
|
419
419
|
var _a;
|
|
420
|
+
const isZodObject = this.zInput._def.typeName === "ZodObject";
|
|
421
|
+
const input = isZodObject ? rawInput ?? {} : rawInput;
|
|
420
422
|
const pInput = this.zInput.safeParse(input);
|
|
421
423
|
if (!pInput.success) {
|
|
422
424
|
throw new Error(`Tool "${this.name}" received invalid input: ${pInput.error.message}`);
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
var _chunkQRFGEFROcjs = require('./chunk-QRFGEFRO.cjs');
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkWP7SDPJ6cjs = require('./chunk-WP7SDPJ6.cjs');
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
var _chunkPK72FAKDcjs = require('./chunk-PK72FAKD.cjs');
|
|
@@ -1274,7 +1274,7 @@ var Context = (_class2 = class {
|
|
|
1274
1274
|
var _a, _b;
|
|
1275
1275
|
const instructions = await getValue(this.instructions, this);
|
|
1276
1276
|
const transcript = new TranscriptArray(await getValue(_nullishCoalesce(((_a = this.chat) == null ? void 0 : _a.transcript), () => ( [])), this));
|
|
1277
|
-
const tools =
|
|
1277
|
+
const tools = _chunkWP7SDPJ6cjs.Tool.withUniqueNames(await _asyncNullishCoalesce(await getValue(this.tools, this), async () => ( [])));
|
|
1278
1278
|
const objects = await _asyncNullishCoalesce(await getValue(this.objects, this), async () => ( []));
|
|
1279
1279
|
const exits = await _asyncNullishCoalesce(await getValue(this.exits, this), async () => ( []));
|
|
1280
1280
|
const components = await getValue(_nullishCoalesce(((_b = this.chat) == null ? void 0 : _b.components), () => ( [])), this);
|
|
@@ -1306,7 +1306,7 @@ var Context = (_class2 = class {
|
|
|
1306
1306
|
"boolean",
|
|
1307
1307
|
"array"
|
|
1308
1308
|
];
|
|
1309
|
-
const MessageTool = this.chat && components.length ? new (0,
|
|
1309
|
+
const MessageTool = this.chat && components.length ? new (0, _chunkWP7SDPJ6cjs.Tool)({
|
|
1310
1310
|
name: "Message",
|
|
1311
1311
|
description: "Send a message to the user",
|
|
1312
1312
|
aliases: Array.from(
|
|
@@ -415,8 +415,10 @@ var Tool = (_class = class _Tool {
|
|
|
415
415
|
*
|
|
416
416
|
* @internal This method is primarily used internally by the LLMz execution engine
|
|
417
417
|
*/
|
|
418
|
-
async execute(
|
|
418
|
+
async execute(rawInput, ctx) {
|
|
419
419
|
var _a;
|
|
420
|
+
const isZodObject = this.zInput._def.typeName === "ZodObject";
|
|
421
|
+
const input = isZodObject ? _nullishCoalesce(rawInput, () => ( {})) : rawInput;
|
|
420
422
|
const pInput = this.zInput.safeParse(input);
|
|
421
423
|
if (!pInput.success) {
|
|
422
424
|
throw new Error(`Tool "${this.name}" received invalid input: ${pInput.error.message}`);
|
package/dist/index.cjs
CHANGED
|
@@ -9,11 +9,11 @@
|
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _chunkRD3LPQOWcjs = require('./chunk-RD3LPQOW.cjs');
|
|
13
13
|
require('./chunk-QRFGEFRO.cjs');
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunkWP7SDPJ6cjs = require('./chunk-WP7SDPJ6.cjs');
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
@@ -428,7 +428,7 @@ var ObjectInstance = class {
|
|
|
428
428
|
this.description = props.description;
|
|
429
429
|
this.metadata = _nullishCoalesce(props.metadata, () => ( {}));
|
|
430
430
|
this.properties = props.properties;
|
|
431
|
-
this.tools =
|
|
431
|
+
this.tools = _chunkWP7SDPJ6cjs.Tool.withUniqueNames(_nullishCoalesce(props.tools, () => ( [])));
|
|
432
432
|
}
|
|
433
433
|
/**
|
|
434
434
|
* Generates TypeScript namespace declarations for this object.
|
|
@@ -1112,13 +1112,13 @@ var utils = {
|
|
|
1112
1112
|
truncateWrappedContent: _chunkGZPN7RGHcjs.truncateWrappedContent
|
|
1113
1113
|
};
|
|
1114
1114
|
var execute = async (props) => {
|
|
1115
|
-
const { executeContext } = await Promise.resolve().then(() => _interopRequireWildcard(require("./llmz-
|
|
1115
|
+
const { executeContext } = await Promise.resolve().then(() => _interopRequireWildcard(require("./llmz-I7RVUI6Q.cjs")));
|
|
1116
1116
|
return executeContext(props);
|
|
1117
1117
|
};
|
|
1118
1118
|
var init = async () => {
|
|
1119
|
-
await Promise.resolve().then(() => _interopRequireWildcard(require("./llmz-
|
|
1119
|
+
await Promise.resolve().then(() => _interopRequireWildcard(require("./llmz-I7RVUI6Q.cjs")));
|
|
1120
1120
|
await Promise.resolve().then(() => _interopRequireWildcard(require("./component-AAEMNCHB.cjs")));
|
|
1121
|
-
await Promise.resolve().then(() => _interopRequireWildcard(require("./tool-
|
|
1121
|
+
await Promise.resolve().then(() => _interopRequireWildcard(require("./tool-OC3QHJWX.cjs")));
|
|
1122
1122
|
await Promise.resolve().then(() => _interopRequireWildcard(require("./exit-XAYKJ6TR.cjs")));
|
|
1123
1123
|
await Promise.resolve().then(() => _interopRequireWildcard(require("./jsx-AJAXBWFE.cjs")));
|
|
1124
1124
|
await Promise.resolve().then(() => _interopRequireWildcard(require("./vm-VFORKC54.cjs")));
|
|
@@ -1155,4 +1155,4 @@ var init = async () => {
|
|
|
1155
1155
|
|
|
1156
1156
|
|
|
1157
1157
|
|
|
1158
|
-
exports.Chat = Chat; exports.CitationsManager = CitationsManager; exports.Component = _chunkQY2TRWGKcjs.Component; exports.DefaultComponents = DefaultComponents; exports.DefaultExit =
|
|
1158
|
+
exports.Chat = Chat; exports.CitationsManager = CitationsManager; exports.Component = _chunkQY2TRWGKcjs.Component; exports.DefaultComponents = DefaultComponents; exports.DefaultExit = _chunkRD3LPQOWcjs.DefaultExit; exports.ErrorExecutionResult = _chunkRD3LPQOWcjs.ErrorExecutionResult; exports.ExecutionResult = _chunkRD3LPQOWcjs.ExecutionResult; exports.Exit = _chunk3G3BS5IAcjs.Exit; exports.ListenExit = _chunkRD3LPQOWcjs.ListenExit; exports.LoopExceededError = _chunkPK72FAKDcjs.LoopExceededError; exports.ObjectInstance = ObjectInstance; exports.PartialExecutionResult = _chunkRD3LPQOWcjs.PartialExecutionResult; exports.Snapshot = _chunkRD3LPQOWcjs.Snapshot; exports.SnapshotSignal = _chunkPK72FAKDcjs.SnapshotSignal; exports.SuccessExecutionResult = _chunkRD3LPQOWcjs.SuccessExecutionResult; exports.ThinkExit = _chunkRD3LPQOWcjs.ThinkExit; exports.ThinkSignal = _chunkPK72FAKDcjs.ThinkSignal; exports.Tool = _chunkWP7SDPJ6cjs.Tool; exports.assertValidComponent = _chunkQY2TRWGKcjs.assertValidComponent; exports.execute = execute; exports.getValue = _chunkRD3LPQOWcjs.getValue; exports.init = init; exports.isAnyComponent = _chunkQY2TRWGKcjs.isAnyComponent; exports.isComponent = _chunkQY2TRWGKcjs.isComponent; exports.parseExit = _chunkRD3LPQOWcjs.parseExit; exports.renderToTsx = _chunkQY2TRWGKcjs.renderToTsx; exports.utils = utils;
|
package/dist/index.js
CHANGED
|
@@ -9,11 +9,11 @@ import {
|
|
|
9
9
|
ThinkExit,
|
|
10
10
|
getValue,
|
|
11
11
|
parseExit
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-4KXGNHLO.js";
|
|
13
13
|
import "./chunk-DOIKBDLR.js";
|
|
14
14
|
import {
|
|
15
15
|
Tool
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-PUFOVD74.js";
|
|
17
17
|
import {
|
|
18
18
|
formatTypings,
|
|
19
19
|
getTypings
|
|
@@ -1112,13 +1112,13 @@ var utils = {
|
|
|
1112
1112
|
truncateWrappedContent
|
|
1113
1113
|
};
|
|
1114
1114
|
var execute = async (props) => {
|
|
1115
|
-
const { executeContext } = await import("./llmz-
|
|
1115
|
+
const { executeContext } = await import("./llmz-7KVW3LXE.js");
|
|
1116
1116
|
return executeContext(props);
|
|
1117
1117
|
};
|
|
1118
1118
|
var init = async () => {
|
|
1119
|
-
await import("./llmz-
|
|
1119
|
+
await import("./llmz-7KVW3LXE.js");
|
|
1120
1120
|
await import("./component-EOMTLA64.js");
|
|
1121
|
-
await import("./tool-
|
|
1121
|
+
await import("./tool-3YL3EY2R.js");
|
|
1122
1122
|
await import("./exit-YLO7BY7Z.js");
|
|
1123
1123
|
await import("./jsx-AEHVFB3L.js");
|
|
1124
1124
|
await import("./vm-Y3WY2627.js");
|
|
@@ -8,9 +8,9 @@ import {
|
|
|
8
8
|
Snapshot,
|
|
9
9
|
SuccessExecutionResult,
|
|
10
10
|
parseExit
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-4KXGNHLO.js";
|
|
12
12
|
import "./chunk-DOIKBDLR.js";
|
|
13
|
-
import "./chunk-
|
|
13
|
+
import "./chunk-PUFOVD74.js";
|
|
14
14
|
import "./chunk-B42FGPCX.js";
|
|
15
15
|
import {
|
|
16
16
|
AssignmentError,
|
|
@@ -44,6 +44,7 @@ import {
|
|
|
44
44
|
} from "./chunk-7WRN4E42.js";
|
|
45
45
|
|
|
46
46
|
// src/llmz.ts
|
|
47
|
+
import { Client } from "@botpress/client";
|
|
47
48
|
import { Cognitive } from "@botpress/cognitive";
|
|
48
49
|
import { z } from "@bpinternal/zui";
|
|
49
50
|
import ms from "ms";
|
|
@@ -105,7 +106,8 @@ var _executeContext = async (props) => {
|
|
|
105
106
|
var _a, _b;
|
|
106
107
|
const controller = createJoinedAbortController([props.signal]);
|
|
107
108
|
const { onIterationStart, onIterationEnd, onTrace, onExit, onBeforeExecution, onAfterTool, onBeforeTool } = props;
|
|
108
|
-
const
|
|
109
|
+
const client = props.client ?? new Client();
|
|
110
|
+
const cognitive = Cognitive.isCognitiveClient(client) ? client : new Cognitive({ client });
|
|
109
111
|
const cleanups = [];
|
|
110
112
|
const ctx = new Context({
|
|
111
113
|
chat: props.chat,
|
|
@@ -219,7 +221,7 @@ var executeIteration = async ({
|
|
|
219
221
|
onBeforeTool,
|
|
220
222
|
onAfterTool
|
|
221
223
|
}) => {
|
|
222
|
-
var _a, _b, _c, _d
|
|
224
|
+
var _a, _b, _c, _d;
|
|
223
225
|
let startedAt = Date.now();
|
|
224
226
|
const traces = iteration.traces;
|
|
225
227
|
const model = await cognitive.getModelDetails(Array.isArray(iteration.model) ? iteration.model[0] : iteration.model);
|
|
@@ -252,7 +254,7 @@ var executeIteration = async ({
|
|
|
252
254
|
messages: messages.filter((x) => x.role !== "system"),
|
|
253
255
|
stopSequences: ctx.version.getStopTokens()
|
|
254
256
|
});
|
|
255
|
-
const out = ((_c = (_b = output.output.choices) == null ? void 0 : _b[0]) == null ? void 0 : _c.
|
|
257
|
+
const out = typeof ((_c = (_b = output.output.choices) == null ? void 0 : _b[0]) == null ? void 0 : _c.content) === "string" ? output.output.choices[0].content : null;
|
|
256
258
|
if (!out) {
|
|
257
259
|
throw new CognitiveError("LLM did not return any text output");
|
|
258
260
|
}
|
|
@@ -428,7 +430,7 @@ var executeIteration = async ({
|
|
|
428
430
|
return iteration.end({
|
|
429
431
|
type: "execution_error",
|
|
430
432
|
execution_error: {
|
|
431
|
-
message: ((
|
|
433
|
+
message: ((_d = result == null ? void 0 : result.error) == null ? void 0 : _d.message) ?? "Unknown error occurred",
|
|
432
434
|
stack: cleanStackTrace(result.error.stack ?? "No stack trace available")
|
|
433
435
|
}
|
|
434
436
|
});
|
|
@@ -8,9 +8,9 @@ var _chunk5FWOHMO4cjs = require('./chunk-5FWOHMO4.cjs');
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkRD3LPQOWcjs = require('./chunk-RD3LPQOW.cjs');
|
|
12
12
|
require('./chunk-QRFGEFRO.cjs');
|
|
13
|
-
require('./chunk-
|
|
13
|
+
require('./chunk-WP7SDPJ6.cjs');
|
|
14
14
|
require('./chunk-KED57HR5.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
@@ -44,6 +44,7 @@ var _chunkWHNOR4ZUcjs = require('./chunk-WHNOR4ZU.cjs');
|
|
|
44
44
|
var _chunkUQOBUJIQcjs = require('./chunk-UQOBUJIQ.cjs');
|
|
45
45
|
|
|
46
46
|
// src/llmz.ts
|
|
47
|
+
var _client = require('@botpress/client');
|
|
47
48
|
var _cognitive = require('@botpress/cognitive');
|
|
48
49
|
var _zui = require('@bpinternal/zui');
|
|
49
50
|
var _ms = require('ms'); var _ms2 = _interopRequireDefault(_ms);
|
|
@@ -105,9 +106,10 @@ var _executeContext = async (props) => {
|
|
|
105
106
|
var _a, _b;
|
|
106
107
|
const controller = createJoinedAbortController([props.signal]);
|
|
107
108
|
const { onIterationStart, onIterationEnd, onTrace, onExit, onBeforeExecution, onAfterTool, onBeforeTool } = props;
|
|
108
|
-
const
|
|
109
|
+
const client = _nullishCoalesce(props.client, () => ( new (0, _client.Client)()));
|
|
110
|
+
const cognitive = _cognitive.Cognitive.isCognitiveClient(client) ? client : new (0, _cognitive.Cognitive)({ client });
|
|
109
111
|
const cleanups = [];
|
|
110
|
-
const ctx = new (0,
|
|
112
|
+
const ctx = new (0, _chunkRD3LPQOWcjs.Context)({
|
|
111
113
|
chat: props.chat,
|
|
112
114
|
instructions: props.instructions,
|
|
113
115
|
objects: props.objects,
|
|
@@ -122,7 +124,7 @@ var _executeContext = async (props) => {
|
|
|
122
124
|
try {
|
|
123
125
|
while (true) {
|
|
124
126
|
if (ctx.iterations.length >= ctx.loop) {
|
|
125
|
-
return new (0,
|
|
127
|
+
return new (0, _chunkRD3LPQOWcjs.ErrorExecutionResult)(ctx, new (0, _chunkPK72FAKDcjs.LoopExceededError)());
|
|
126
128
|
}
|
|
127
129
|
const iteration = await ctx.nextIteration();
|
|
128
130
|
try {
|
|
@@ -145,7 +147,7 @@ var _executeContext = async (props) => {
|
|
|
145
147
|
reason: _nullishCoalesce(controller.signal.reason, () => ( "The operation was aborted"))
|
|
146
148
|
}
|
|
147
149
|
});
|
|
148
|
-
return new (0,
|
|
150
|
+
return new (0, _chunkRD3LPQOWcjs.ErrorExecutionResult)(ctx, _nullishCoalesce(controller.signal.reason, () => ( "The operation was aborted")));
|
|
149
151
|
}
|
|
150
152
|
cleanups.push(
|
|
151
153
|
iteration.traces.onPush((traces) => {
|
|
@@ -181,25 +183,25 @@ var _executeContext = async (props) => {
|
|
|
181
183
|
}
|
|
182
184
|
if (iteration.status.type === "exit_success") {
|
|
183
185
|
const exitName = iteration.status.exit_success.exit_name;
|
|
184
|
-
return new (0,
|
|
186
|
+
return new (0, _chunkRD3LPQOWcjs.SuccessExecutionResult)(ctx, {
|
|
185
187
|
exit: iteration.exits.find((x) => x.name === exitName),
|
|
186
188
|
result: iteration.status.exit_success.return_value
|
|
187
189
|
});
|
|
188
190
|
}
|
|
189
191
|
if (iteration.status.type === "callback_requested") {
|
|
190
|
-
return new (0,
|
|
192
|
+
return new (0, _chunkRD3LPQOWcjs.PartialExecutionResult)(
|
|
191
193
|
ctx,
|
|
192
194
|
iteration.status.callback_requested.signal,
|
|
193
|
-
|
|
195
|
+
_chunkRD3LPQOWcjs.Snapshot.fromSignal(iteration.status.callback_requested.signal)
|
|
194
196
|
);
|
|
195
197
|
}
|
|
196
198
|
if (iteration.status.type === "thinking_requested" || iteration.status.type === "exit_error" || iteration.status.type === "execution_error" || iteration.status.type === "invalid_code_error") {
|
|
197
199
|
continue;
|
|
198
200
|
}
|
|
199
|
-
return new (0,
|
|
201
|
+
return new (0, _chunkRD3LPQOWcjs.ErrorExecutionResult)(ctx, _nullishCoalesce(iteration.error, () => ( `Unknown error. Status: ${iteration.status.type}`)));
|
|
200
202
|
}
|
|
201
203
|
} catch (error) {
|
|
202
|
-
return new (0,
|
|
204
|
+
return new (0, _chunkRD3LPQOWcjs.ErrorExecutionResult)(ctx, _nullishCoalesce(error, () => ( "Unknown error")));
|
|
203
205
|
} finally {
|
|
204
206
|
for (const cleanup of cleanups) {
|
|
205
207
|
try {
|
|
@@ -219,7 +221,7 @@ var executeIteration = async ({
|
|
|
219
221
|
onBeforeTool,
|
|
220
222
|
onAfterTool
|
|
221
223
|
}) => {
|
|
222
|
-
var _a, _b, _c, _d
|
|
224
|
+
var _a, _b, _c, _d;
|
|
223
225
|
let startedAt = Date.now();
|
|
224
226
|
const traces = iteration.traces;
|
|
225
227
|
const model = await cognitive.getModelDetails(Array.isArray(iteration.model) ? iteration.model[0] : iteration.model);
|
|
@@ -252,7 +254,7 @@ var executeIteration = async ({
|
|
|
252
254
|
messages: messages.filter((x) => x.role !== "system"),
|
|
253
255
|
stopSequences: ctx.version.getStopTokens()
|
|
254
256
|
});
|
|
255
|
-
const out = ((_c = (_b = output.output.choices) == null ? void 0 : _b[0]) == null ? void 0 : _c.
|
|
257
|
+
const out = typeof ((_c = (_b = output.output.choices) == null ? void 0 : _b[0]) == null ? void 0 : _c.content) === "string" ? output.output.choices[0].content : null;
|
|
256
258
|
if (!out) {
|
|
257
259
|
throw new (0, _chunkPK72FAKDcjs.CognitiveError)("LLM did not return any text output");
|
|
258
260
|
}
|
|
@@ -428,7 +430,7 @@ var executeIteration = async ({
|
|
|
428
430
|
return iteration.end({
|
|
429
431
|
type: "execution_error",
|
|
430
432
|
execution_error: {
|
|
431
|
-
message: _nullishCoalesce(((
|
|
433
|
+
message: _nullishCoalesce(((_d = result == null ? void 0 : result.error) == null ? void 0 : _d.message), () => ( "Unknown error occurred")),
|
|
432
434
|
stack: _chunkKIN7Y247cjs.cleanStackTrace.call(void 0, _nullishCoalesce(result.error.stack, () => ( "No stack trace available")))
|
|
433
435
|
}
|
|
434
436
|
});
|
|
@@ -472,7 +474,7 @@ var executeIteration = async ({
|
|
|
472
474
|
}
|
|
473
475
|
});
|
|
474
476
|
}
|
|
475
|
-
const parsedExit =
|
|
477
|
+
const parsedExit = _chunkRD3LPQOWcjs.parseExit.call(void 0, returnValue, iteration.exits);
|
|
476
478
|
if (!parsedExit.success) {
|
|
477
479
|
return iteration.end({
|
|
478
480
|
type: "exit_error",
|
package/dist/llmz.d.ts
CHANGED
|
@@ -167,8 +167,9 @@ export type ExecutionProps = {
|
|
|
167
167
|
/**
|
|
168
168
|
* An instance of a Botpress Client, or an instance of Cognitive Client (@botpress/cognitive).
|
|
169
169
|
* This is used to generate content using the LLM and to access the Botpress API.
|
|
170
|
+
* If not provided, a default client will be created using environment variables.
|
|
170
171
|
*/
|
|
171
|
-
client
|
|
172
|
+
client?: Cognitive | BotpressClientLike;
|
|
172
173
|
/**
|
|
173
174
|
* When provided, the execution will immediately stop when the signal is aborted.
|
|
174
175
|
* This will stop the LLM generation, as well as kill the VM sandbox execution.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkWP7SDPJ6cjs = require('./chunk-WP7SDPJ6.cjs');
|
|
4
4
|
require('./chunk-KED57HR5.cjs');
|
|
5
5
|
require('./chunk-PK72FAKD.cjs');
|
|
6
6
|
require('./chunk-KIN7Y247.cjs');
|
|
@@ -8,4 +8,4 @@ require('./chunk-WHNOR4ZU.cjs');
|
|
|
8
8
|
require('./chunk-UQOBUJIQ.cjs');
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
exports.Tool =
|
|
11
|
+
exports.Tool = _chunkWP7SDPJ6cjs.Tool;
|
package/dist/tool.d.ts
CHANGED
|
@@ -464,7 +464,7 @@ export declare class Tool<I extends ZuiType = ZuiType, O extends ZuiType = ZuiTy
|
|
|
464
464
|
*
|
|
465
465
|
* @internal This method is primarily used internally by the LLMz execution engine
|
|
466
466
|
*/
|
|
467
|
-
execute(
|
|
467
|
+
execute(rawInput: TypeOf<I>, ctx: ToolCallContext): Promise<TypeOf<O>>;
|
|
468
468
|
/**
|
|
469
469
|
* Generates TypeScript type definitions for this tool.
|
|
470
470
|
*
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "llmz",
|
|
3
3
|
"type": "module",
|
|
4
4
|
"description": "LLMz – An LLM-native Typescript VM built on top of Zui",
|
|
5
|
-
"version": "0.0.
|
|
5
|
+
"version": "0.0.36",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
7
7
|
"main": "./dist/index.cjs",
|
|
8
8
|
"module": "./dist/index.js",
|
|
@@ -71,10 +71,10 @@
|
|
|
71
71
|
"tsx": "^4.19.2"
|
|
72
72
|
},
|
|
73
73
|
"peerDependencies": {
|
|
74
|
-
"@botpress/client": "1.
|
|
75
|
-
"@botpress/cognitive": "0.3.
|
|
74
|
+
"@botpress/client": "1.28.0",
|
|
75
|
+
"@botpress/cognitive": "0.3.3",
|
|
76
76
|
"@bpinternal/thicktoken": "^1.0.5",
|
|
77
|
-
"@bpinternal/zui": "1.
|
|
77
|
+
"@bpinternal/zui": "1.3.1"
|
|
78
78
|
},
|
|
79
79
|
"dependenciesMeta": {
|
|
80
80
|
"@bpinternal/zui": {
|