@botpress/runtime 1.0.1
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/_types/actions.d.ts +3 -0
- package/dist/_types/actions.d.ts.map +1 -0
- package/dist/_types/events.d.ts +5 -0
- package/dist/_types/events.d.ts.map +1 -0
- package/dist/_types/integration-actions.d.ts +3 -0
- package/dist/_types/integration-actions.d.ts.map +1 -0
- package/dist/_types/state.d.ts +4 -0
- package/dist/_types/state.d.ts.map +1 -0
- package/dist/_types/tables.d.ts +3 -0
- package/dist/_types/tables.d.ts.map +1 -0
- package/dist/_types/triggers.d.ts +3 -0
- package/dist/_types/triggers.d.ts.map +1 -0
- package/dist/_types/workflows.d.ts +12 -0
- package/dist/_types/workflows.d.ts.map +1 -0
- package/dist/constants.d.ts +58 -0
- package/dist/constants.d.ts.map +1 -0
- package/dist/consts.d.ts +8 -0
- package/dist/consts.d.ts.map +1 -0
- package/dist/debugging/node-inspector.d.ts +5 -0
- package/dist/debugging/node-inspector.d.ts.map +1 -0
- package/dist/define-config.d.ts +70 -0
- package/dist/define-config.d.ts.map +1 -0
- package/dist/definition.d.ts +10 -0
- package/dist/definition.d.ts.map +1 -0
- package/dist/definition.js +88 -0
- package/dist/definition.js.map +7 -0
- package/dist/environment.d.ts +60 -0
- package/dist/environment.d.ts.map +1 -0
- package/dist/errors.d.ts +36 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/globals.d.ts +21 -0
- package/dist/globals.d.ts.map +1 -0
- package/dist/internal.d.ts +15 -0
- package/dist/internal.d.ts.map +1 -0
- package/dist/internal.js +46573 -0
- package/dist/internal.js.map +7 -0
- package/dist/library.d.ts +16 -0
- package/dist/library.d.ts.map +1 -0
- package/dist/library.js +45943 -0
- package/dist/library.js.map +7 -0
- package/dist/primitives/action.d.ts +37 -0
- package/dist/primitives/action.d.ts.map +1 -0
- package/dist/primitives/asset.d.ts +28 -0
- package/dist/primitives/asset.d.ts.map +1 -0
- package/dist/primitives/conversation.d.ts +104 -0
- package/dist/primitives/conversation.d.ts.map +1 -0
- package/dist/primitives/data-sources/index.d.ts +7 -0
- package/dist/primitives/data-sources/index.d.ts.map +1 -0
- package/dist/primitives/data-sources/source-base.d.ts +251 -0
- package/dist/primitives/data-sources/source-base.d.ts.map +1 -0
- package/dist/primitives/data-sources/source-directory.d.ts +119 -0
- package/dist/primitives/data-sources/source-directory.d.ts.map +1 -0
- package/dist/primitives/data-sources/source-table.d.ts +135 -0
- package/dist/primitives/data-sources/source-table.d.ts.map +1 -0
- package/dist/primitives/data-sources/source-website.d.ts +226 -0
- package/dist/primitives/data-sources/source-website.d.ts.map +1 -0
- package/dist/primitives/definition.d.ts +68 -0
- package/dist/primitives/definition.d.ts.map +1 -0
- package/dist/primitives/index.d.ts +149 -0
- package/dist/primitives/index.d.ts.map +1 -0
- package/dist/primitives/knowledge.d.ts +36 -0
- package/dist/primitives/knowledge.d.ts.map +1 -0
- package/dist/primitives/table.d.ts +153 -0
- package/dist/primitives/table.d.ts.map +1 -0
- package/dist/primitives/trigger.d.ts +26 -0
- package/dist/primitives/trigger.d.ts.map +1 -0
- package/dist/primitives/workflow-instance.d.ts +80 -0
- package/dist/primitives/workflow-instance.d.ts.map +1 -0
- package/dist/primitives/workflow-step.d.ts +184 -0
- package/dist/primitives/workflow-step.d.ts.map +1 -0
- package/dist/primitives/workflow-utils.d.ts +36 -0
- package/dist/primitives/workflow-utils.d.ts.map +1 -0
- package/dist/primitives/workflow.d.ts +86 -0
- package/dist/primitives/workflow.d.ts.map +1 -0
- package/dist/runtime/actions.d.ts +6 -0
- package/dist/runtime/actions.d.ts.map +1 -0
- package/dist/runtime/adk.d.ts +54 -0
- package/dist/runtime/adk.d.ts.map +1 -0
- package/dist/runtime/agent-registry.d.ts +33 -0
- package/dist/runtime/agent-registry.d.ts.map +1 -0
- package/dist/runtime/assets.d.ts +48 -0
- package/dist/runtime/assets.d.ts.map +1 -0
- package/dist/runtime/autonomous.d.ts +86 -0
- package/dist/runtime/autonomous.d.ts.map +1 -0
- package/dist/runtime/chat/chat.d.ts +42 -0
- package/dist/runtime/chat/chat.d.ts.map +1 -0
- package/dist/runtime/chat/citations.d.ts +9 -0
- package/dist/runtime/chat/citations.d.ts.map +1 -0
- package/dist/runtime/chat/html.d.ts +2 -0
- package/dist/runtime/chat/html.d.ts.map +1 -0
- package/dist/runtime/chat/index.d.ts +5 -0
- package/dist/runtime/chat/index.d.ts.map +1 -0
- package/dist/runtime/chat/messages.d.ts +35 -0
- package/dist/runtime/chat/messages.d.ts.map +1 -0
- package/dist/runtime/chat/transcript.d.ts +75 -0
- package/dist/runtime/chat/transcript.d.ts.map +1 -0
- package/dist/runtime/chat/truncate-object.d.ts +12 -0
- package/dist/runtime/chat/truncate-object.d.ts.map +1 -0
- package/dist/runtime/chat/truncate-transcript.d.ts +6 -0
- package/dist/runtime/chat/truncate-transcript.d.ts.map +1 -0
- package/dist/runtime/config.d.ts +19 -0
- package/dist/runtime/config.d.ts.map +1 -0
- package/dist/runtime/context/cognitive.d.ts +7 -0
- package/dist/runtime/context/cognitive.d.ts.map +1 -0
- package/dist/runtime/context/context.d.ts +59 -0
- package/dist/runtime/context/context.d.ts.map +1 -0
- package/dist/runtime/context/handlers.d.ts +14 -0
- package/dist/runtime/context/handlers.d.ts.map +1 -0
- package/dist/runtime/context/http.d.ts +38 -0
- package/dist/runtime/context/http.d.ts.map +1 -0
- package/dist/runtime/context/inspector-handler.d.ts +59 -0
- package/dist/runtime/context/inspector-handler.d.ts.map +1 -0
- package/dist/runtime/context/promises.d.ts +36 -0
- package/dist/runtime/context/promises.d.ts.map +1 -0
- package/dist/runtime/events.d.ts +89 -0
- package/dist/runtime/events.d.ts.map +1 -0
- package/dist/runtime/handlers/conversation.d.ts +3 -0
- package/dist/runtime/handlers/conversation.d.ts.map +1 -0
- package/dist/runtime/handlers/event.d.ts +3 -0
- package/dist/runtime/handlers/event.d.ts.map +1 -0
- package/dist/runtime/handlers/index.d.ts +11 -0
- package/dist/runtime/handlers/index.d.ts.map +1 -0
- package/dist/runtime/handlers/trigger.d.ts +3 -0
- package/dist/runtime/handlers/trigger.d.ts.map +1 -0
- package/dist/runtime/handlers/workflow.d.ts +3 -0
- package/dist/runtime/handlers/workflow.d.ts.map +1 -0
- package/dist/runtime/heavy-imports.d.ts +10 -0
- package/dist/runtime/heavy-imports.d.ts.map +1 -0
- package/dist/runtime/index.d.ts +13 -0
- package/dist/runtime/index.d.ts.map +1 -0
- package/dist/runtime/interfaces.d.ts +16 -0
- package/dist/runtime/interfaces.d.ts.map +1 -0
- package/dist/runtime/singletons.d.ts +21 -0
- package/dist/runtime/singletons.d.ts.map +1 -0
- package/dist/runtime/state.d.ts +8 -0
- package/dist/runtime/state.d.ts.map +1 -0
- package/dist/runtime/tracked-state-schema.d.ts +36 -0
- package/dist/runtime/tracked-state-schema.d.ts.map +1 -0
- package/dist/runtime/tracked-state.d.ts +57 -0
- package/dist/runtime/tracked-state.d.ts.map +1 -0
- package/dist/runtime/workflows/index.d.ts +7 -0
- package/dist/runtime/workflows/index.d.ts.map +1 -0
- package/dist/runtime/workflows/knowledge-indexing.d.ts +109 -0
- package/dist/runtime/workflows/knowledge-indexing.d.ts.map +1 -0
- package/dist/runtime.d.ts +22 -0
- package/dist/runtime.d.ts.map +1 -0
- package/dist/runtime.js +47545 -0
- package/dist/runtime.js.map +7 -0
- package/dist/telemetry/context-manager.d.ts +16 -0
- package/dist/telemetry/context-manager.d.ts.map +1 -0
- package/dist/telemetry/file-exporter.d.ts +11 -0
- package/dist/telemetry/file-exporter.d.ts.map +1 -0
- package/dist/telemetry/instrument-http.d.ts +4 -0
- package/dist/telemetry/instrument-http.d.ts.map +1 -0
- package/dist/telemetry/live-file-processor.d.ts +13 -0
- package/dist/telemetry/live-file-processor.d.ts.map +1 -0
- package/dist/telemetry/span-helpers.d.ts +30 -0
- package/dist/telemetry/span-helpers.d.ts.map +1 -0
- package/dist/telemetry/spans/factory.d.ts +44 -0
- package/dist/telemetry/spans/factory.d.ts.map +1 -0
- package/dist/telemetry/spans/index.d.ts +1009 -0
- package/dist/telemetry/spans/index.d.ts.map +1 -0
- package/dist/telemetry/spans/well-known-attributes.d.ts +78 -0
- package/dist/telemetry/spans/well-known-attributes.d.ts.map +1 -0
- package/dist/telemetry/structured-logging.d.ts +34 -0
- package/dist/telemetry/structured-logging.d.ts.map +1 -0
- package/dist/telemetry/tracing.d.ts +6 -0
- package/dist/telemetry/tracing.d.ts.map +1 -0
- package/dist/telemetry/utils.d.ts +3 -0
- package/dist/telemetry/utils.d.ts.map +1 -0
- package/dist/types.d.ts +17 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/ui.d.ts +10 -0
- package/dist/ui.d.ts.map +1 -0
- package/dist/ui.js +749 -0
- package/dist/ui.js.map +7 -0
- package/dist/utilities/abort-signal.d.ts +41 -0
- package/dist/utilities/abort-signal.d.ts.map +1 -0
- package/dist/utilities/events.d.ts +10 -0
- package/dist/utilities/events.d.ts.map +1 -0
- package/dist/utilities/promises.d.ts +3 -0
- package/dist/utilities/promises.d.ts.map +1 -0
- package/dist/utilities/size.d.ts +12 -0
- package/dist/utilities/size.d.ts.map +1 -0
- package/dist/utilities/strings.d.ts +18 -0
- package/dist/utilities/strings.d.ts.map +1 -0
- package/dist/utilities/trigger-tags.d.ts +31 -0
- package/dist/utilities/trigger-tags.d.ts.map +1 -0
- package/dist/utilities/types.d.ts +2 -0
- package/dist/utilities/types.d.ts.map +1 -0
- package/dist/workers/dev_worker.d.ts +6 -0
- package/dist/workers/dev_worker.d.ts.map +1 -0
- package/dist/workers/index.d.ts +5 -0
- package/dist/workers/index.d.ts.map +1 -0
- package/dist/workers/parent_worker.d.ts +5 -0
- package/dist/workers/parent_worker.d.ts.map +1 -0
- package/dist/workers/worker_pool.d.ts +109 -0
- package/dist/workers/worker_pool.d.ts.map +1 -0
- package/package.json +109 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../../src/runtime/context/http.ts"],"names":[],"mappings":"AAUA,MAAM,MAAM,cAAc,GAAG;IAC3B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,EAAE,GAAG,CAAC;IACV,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC9B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,MAAM,EAAE,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,QAAQ,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,CAAC;IACzE,GAAG,EAAE;QACH,EAAE,EAAE,MAAM,CAAC;QACX,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QAC7B,iBAAiB,EAAE,MAAM,CAAC;QAC1B,aAAa,EAAE;YACb,EAAE,EAAE,MAAM,CAAC;YACX,SAAS,EAAE,MAAM,CAAC;YAClB,SAAS,EAAE,MAAM,CAAC;YAClB,IAAI,EAAE,KAAK,CAAC;YACZ,OAAO,EAAE,GAAG,CAAC;SACd,CAAC;KACH,CAAC;IAEF,SAAS,EAAE,UAAU,GAAG,gBAAgB,GAAG,MAAM,GAAG,kBAAkB,CAAC;IACvE,IAAI,EACA,UAAU,GACV,iBAAiB,GACjB,iBAAiB,GACjB,eAAe,GACf,CAAC,MAAM,GAAG,EAAE,CAAC,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,GAAG,EAAE;QACH,IAAI,EAAE,MAAM,CAAC;QACb,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QAChC,MAAM,EAAE,MAAM,CAAC;KAChB,CAAC;CACH,CAAC;AAiDF,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,cAAc,GAAG,WAAW,CAiFjE"}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Inspector Handler
|
|
3
|
+
*
|
|
4
|
+
* Provides a debug endpoint for starting the Node.js inspector at runtime.
|
|
5
|
+
* When a POST request is made to /__debug/inspector, this handler:
|
|
6
|
+
* 1. Opens the Node.js inspector on a random port
|
|
7
|
+
* 2. Fetches inspector metadata from http://127.0.0.1:[PORT]/json/list
|
|
8
|
+
* 3. Returns the DevTools frontend URL, inspector port, and process PID
|
|
9
|
+
*
|
|
10
|
+
* This allows developers to attach debuggers (Chrome DevTools, VSCode) to
|
|
11
|
+
* running bot processes for debugging with full source map support.
|
|
12
|
+
*/
|
|
13
|
+
export interface InspectorResponse {
|
|
14
|
+
inspectorUrl: string | null;
|
|
15
|
+
inspectorPort: number | null;
|
|
16
|
+
webSocketDebuggerUrl: string | null;
|
|
17
|
+
devtoolsFrontendUrl: string | null;
|
|
18
|
+
pid: number;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Checks if the inspector is currently active.
|
|
22
|
+
*
|
|
23
|
+
* @returns True if inspector is open, false otherwise
|
|
24
|
+
*/
|
|
25
|
+
export declare function isInspectorActive(): Promise<boolean>;
|
|
26
|
+
/**
|
|
27
|
+
* Closes the Node.js inspector if it's currently open.
|
|
28
|
+
*
|
|
29
|
+
* @returns HTTP response indicating success or failure
|
|
30
|
+
*/
|
|
31
|
+
export declare function handleInspectorDisable(): Promise<{
|
|
32
|
+
statusCode: number;
|
|
33
|
+
headers: Record<string, string>;
|
|
34
|
+
body: string;
|
|
35
|
+
}>;
|
|
36
|
+
/**
|
|
37
|
+
* Handles the inspector debug request.
|
|
38
|
+
* Just returns the PID without starting the inspector.
|
|
39
|
+
* This allows VSCode to attach and start the inspector itself.
|
|
40
|
+
*
|
|
41
|
+
* @returns HTTP response with PID information
|
|
42
|
+
*/
|
|
43
|
+
export declare function handleInspectorRequest(): Promise<{
|
|
44
|
+
statusCode: number;
|
|
45
|
+
headers: Record<string, string>;
|
|
46
|
+
body: string;
|
|
47
|
+
}>;
|
|
48
|
+
/**
|
|
49
|
+
* Handles Chrome DevTools open request.
|
|
50
|
+
* Starts the inspector if not already started and returns the DevTools URL.
|
|
51
|
+
*
|
|
52
|
+
* @returns HTTP response with inspector connection information
|
|
53
|
+
*/
|
|
54
|
+
export declare function handleInspectorChrome(): Promise<{
|
|
55
|
+
statusCode: number;
|
|
56
|
+
headers: Record<string, string>;
|
|
57
|
+
body: string;
|
|
58
|
+
}>;
|
|
59
|
+
//# sourceMappingURL=inspector-handler.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inspector-handler.d.ts","sourceRoot":"","sources":["../../../src/runtime/context/inspector-handler.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,MAAM,WAAW,iBAAiB;IAChC,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,aAAa,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,oBAAoB,EAAE,MAAM,GAAG,IAAI,CAAC;IACpC,mBAAmB,EAAE,MAAM,GAAG,IAAI,CAAC;IACnC,GAAG,EAAE,MAAM,CAAC;CACb;AAED;;;;GAIG;AACH,wBAAsB,iBAAiB,IAAI,OAAO,CAAC,OAAO,CAAC,CAG1D;AAED;;;;GAIG;AACH,wBAAsB,sBAAsB,IAAI,OAAO,CAAC;IACtD,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,IAAI,EAAE,MAAM,CAAC;CACd,CAAC,CAaD;AAED;;;;;;GAMG;AACH,wBAAsB,sBAAsB,IAAI,OAAO,CAAC;IACtD,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,IAAI,EAAE,MAAM,CAAC;CACd,CAAC,CAgBD;AAED;;;;;GAKG;AACH,wBAAsB,qBAAqB,IAAI,OAAO,CAAC;IACrD,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,IAAI,EAAE,MAAM,CAAC;CACd,CAAC,CAiDD"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
export declare class PromiseTracker {
|
|
2
|
+
private promises;
|
|
3
|
+
private isShuttingDown;
|
|
4
|
+
reset(): void;
|
|
5
|
+
/**
|
|
6
|
+
* Register a promise to be tracked
|
|
7
|
+
*/
|
|
8
|
+
register<T>(promise: Promise<T>): Promise<T>;
|
|
9
|
+
shutdown(): Promise<void>;
|
|
10
|
+
/**
|
|
11
|
+
* Wait for all registered promises to settle
|
|
12
|
+
*/
|
|
13
|
+
awaitAll(): Promise<PromiseSettledResult<any>[]>;
|
|
14
|
+
/**
|
|
15
|
+
* Get the number of currently tracked promises
|
|
16
|
+
*/
|
|
17
|
+
get count(): number;
|
|
18
|
+
/**
|
|
19
|
+
* Check if there are any pending promises
|
|
20
|
+
*/
|
|
21
|
+
get hasPending(): boolean;
|
|
22
|
+
/**
|
|
23
|
+
* Get a snapshot of currently tracked promises
|
|
24
|
+
*/
|
|
25
|
+
getSnapshot(): Promise<any>[];
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Convenience function to register a promise with the context's PromiseTracker
|
|
29
|
+
*/
|
|
30
|
+
export declare function trackPromise<T>(promise: Promise<T>): Promise<T>;
|
|
31
|
+
/**
|
|
32
|
+
* Await all tracked promises to settle
|
|
33
|
+
*
|
|
34
|
+
*/
|
|
35
|
+
export declare function shutdownPromiseTracker(): Promise<void>;
|
|
36
|
+
//# sourceMappingURL=promises.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"promises.d.ts","sourceRoot":"","sources":["../../../src/runtime/context/promises.ts"],"names":[],"mappings":"AAEA,qBAAa,cAAc;IACzB,OAAO,CAAC,QAAQ,CAAgC;IAChD,OAAO,CAAC,cAAc,CAAS;IAE/B,KAAK;IAKL;;OAEG;IACH,QAAQ,CAAC,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC;IAgBtC,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;IAK/B;;OAEG;IACG,QAAQ,IAAI,OAAO,CAAC,oBAAoB,CAAC,GAAG,CAAC,EAAE,CAAC;IAWtD;;OAEG;IACH,IAAI,KAAK,IAAI,MAAM,CAElB;IAED;;OAEG;IACH,IAAI,UAAU,IAAI,OAAO,CAExB;IAED;;OAEG;IACH,WAAW,IAAI,OAAO,CAAC,GAAG,CAAC,EAAE;CAG9B;AAaD;;GAEG;AACH,wBAAgB,YAAY,CAAC,CAAC,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAE/D;AAED;;;GAGG;AACH,wBAAsB,sBAAsB,IAAI,OAAO,CAAC,IAAI,CAAC,CAE5D"}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
export declare const WorkflowCallbackEvent: {
|
|
2
|
+
name: "workflowCallback";
|
|
3
|
+
schema: import("@bpinternal/zui").ZodObject<{
|
|
4
|
+
workflow: import("@bpinternal/zui").ZodString;
|
|
5
|
+
workflowId: import("@bpinternal/zui").ZodString;
|
|
6
|
+
target: import("@bpinternal/zui").ZodUnion<[import("@bpinternal/zui").ZodObject<{
|
|
7
|
+
conversationId: import("@bpinternal/zui").ZodString;
|
|
8
|
+
}, "strip", {
|
|
9
|
+
conversationId: string;
|
|
10
|
+
}, {
|
|
11
|
+
conversationId: string;
|
|
12
|
+
}>, import("@bpinternal/zui").ZodObject<{
|
|
13
|
+
workflowId: import("@bpinternal/zui").ZodString;
|
|
14
|
+
}, "strip", {
|
|
15
|
+
workflowId: string;
|
|
16
|
+
}, {
|
|
17
|
+
workflowId: string;
|
|
18
|
+
}>]>;
|
|
19
|
+
status: import("@bpinternal/zui").ZodEnum<["completed", "failed", "canceled", "timed_out"]>;
|
|
20
|
+
output: import("@bpinternal/zui").ZodOptional<import("@bpinternal/zui").ZodAny>;
|
|
21
|
+
error: import("@bpinternal/zui").ZodOptional<import("@bpinternal/zui").ZodString>;
|
|
22
|
+
}, "strip", {
|
|
23
|
+
workflowId: string;
|
|
24
|
+
status: "completed" | "failed" | "canceled" | "timed_out";
|
|
25
|
+
workflow: string;
|
|
26
|
+
target: {
|
|
27
|
+
conversationId: string;
|
|
28
|
+
} | {
|
|
29
|
+
workflowId: string;
|
|
30
|
+
};
|
|
31
|
+
error?: string | undefined;
|
|
32
|
+
output?: any;
|
|
33
|
+
}, {
|
|
34
|
+
workflowId: string;
|
|
35
|
+
status: "completed" | "failed" | "canceled" | "timed_out";
|
|
36
|
+
workflow: string;
|
|
37
|
+
target: {
|
|
38
|
+
conversationId: string;
|
|
39
|
+
} | {
|
|
40
|
+
workflowId: string;
|
|
41
|
+
};
|
|
42
|
+
error?: string | undefined;
|
|
43
|
+
output?: any;
|
|
44
|
+
}>;
|
|
45
|
+
};
|
|
46
|
+
export declare const WorkflowScheduleEvent: {
|
|
47
|
+
name: "workflowSchedule";
|
|
48
|
+
schema: import("@bpinternal/zui").ZodObject<{
|
|
49
|
+
workflow: import("@bpinternal/zui").ZodString;
|
|
50
|
+
}, "strip", {
|
|
51
|
+
workflow: string;
|
|
52
|
+
}, {
|
|
53
|
+
workflow: string;
|
|
54
|
+
}>;
|
|
55
|
+
};
|
|
56
|
+
export declare const WorkflowContinueEvent: {
|
|
57
|
+
name: "workflowContinue";
|
|
58
|
+
schema: import("@bpinternal/zui").ZodObject<{}, "strip", {}, {}>;
|
|
59
|
+
};
|
|
60
|
+
export declare const SubworkflowFinished: {
|
|
61
|
+
name: "subworkflowFinished";
|
|
62
|
+
schema: import("@bpinternal/zui").ZodObject<{}, "strip", {}, {}>;
|
|
63
|
+
};
|
|
64
|
+
export declare const WorkflowDataRequestEvent: {
|
|
65
|
+
name: "workflowDataRequest";
|
|
66
|
+
schema: import("@bpinternal/zui").ZodObject<{
|
|
67
|
+
workflowId: import("@bpinternal/zui").ZodString;
|
|
68
|
+
workflowName: import("@bpinternal/zui").ZodString;
|
|
69
|
+
stepName: import("@bpinternal/zui").ZodString;
|
|
70
|
+
request: import("@bpinternal/zui").ZodString;
|
|
71
|
+
message: import("@bpinternal/zui").ZodString;
|
|
72
|
+
schema: import("@bpinternal/zui").ZodAny;
|
|
73
|
+
}, "strip", {
|
|
74
|
+
workflowId: string;
|
|
75
|
+
message: string;
|
|
76
|
+
request: string;
|
|
77
|
+
workflowName: string;
|
|
78
|
+
stepName: string;
|
|
79
|
+
schema?: any;
|
|
80
|
+
}, {
|
|
81
|
+
workflowId: string;
|
|
82
|
+
message: string;
|
|
83
|
+
request: string;
|
|
84
|
+
workflowName: string;
|
|
85
|
+
stepName: string;
|
|
86
|
+
schema?: any;
|
|
87
|
+
}>;
|
|
88
|
+
};
|
|
89
|
+
//# sourceMappingURL=events.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../src/runtime/events.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiBP,CAAC;AAE5B,eAAO,MAAM,qBAAqB;;;;;;;;;CAKP,CAAC;AAE5B,eAAO,MAAM,qBAAqB;;;CAGjC,CAAC;AAEF,eAAO,MAAM,mBAAmB;;;CAG/B,CAAC;AAEF,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;CAUV,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"conversation.d.ts","sourceRoot":"","sources":["../../../src/runtime/handlers/conversation.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AAQ/E,eAAO,MAAM,KAAK,GAAI,KAAK,iBAAiB,SAsE3C,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"event.d.ts","sourceRoot":"","sources":["../../../src/runtime/handlers/event.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AAgB/E,eAAO,MAAM,KAAK,GAAI,KAAK,iBAAiB,SA+H3C,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as conversation from "./conversation";
|
|
2
|
+
import * as trigger from "./trigger";
|
|
3
|
+
import * as workflow from "./workflow";
|
|
4
|
+
import * as event from "./event";
|
|
5
|
+
export declare const handlers: {
|
|
6
|
+
conversation: typeof conversation;
|
|
7
|
+
trigger: typeof trigger;
|
|
8
|
+
workflow: typeof workflow;
|
|
9
|
+
event: typeof event;
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/runtime/handlers/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,YAAY,MAAM,gBAAgB,CAAC;AAC/C,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AACrC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AAEjC,eAAO,MAAM,QAAQ;;;;;CAKpB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"trigger.d.ts","sourceRoot":"","sources":["../../../src/runtime/handlers/trigger.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AAK/E,eAAO,MAAM,KAAK,GAAI,KAAK,iBAAiB,SAiE3C,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"workflow.d.ts","sourceRoot":"","sources":["../../../src/runtime/handlers/workflow.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AAkB/E,eAAO,MAAM,KAAK,GAAI,KAAK,iBAAiB,SA0O3C,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
declare const HEAVY_IMPORTS: {
|
|
2
|
+
readonly sdk: () => any;
|
|
3
|
+
readonly client: () => any;
|
|
4
|
+
readonly llmz: () => Promise<void>;
|
|
5
|
+
};
|
|
6
|
+
export declare const scheduleHeavyImport: (key: keyof typeof HEAVY_IMPORTS) => void;
|
|
7
|
+
export declare const clearScheduledHeavyImports: () => void;
|
|
8
|
+
export declare const importScheduledHeavyImports: () => Promise<void>;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=heavy-imports.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"heavy-imports.d.ts","sourceRoot":"","sources":["../../src/runtime/heavy-imports.ts"],"names":[],"mappings":"AAEA,QAAA,MAAM,aAAa;wBACqB,GAAG;2BACG,GAAG;;CAKvC,CAAC;AAEX,eAAO,MAAM,mBAAmB,GAAI,KAAK,MAAM,OAAO,aAAa,SAElE,CAAC;AAEF,eAAO,MAAM,0BAA0B,YAEtC,CAAC;AAEF,eAAO,MAAM,2BAA2B,qBAWvC,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export * from "./assets";
|
|
2
|
+
export * from "./context/context";
|
|
3
|
+
export * from "./context/handlers";
|
|
4
|
+
export * from "./context/promises";
|
|
5
|
+
export * from "./chat";
|
|
6
|
+
export * from "./handlers";
|
|
7
|
+
export * from "./interfaces";
|
|
8
|
+
export * from "./tracked-state";
|
|
9
|
+
export * from "./tracked-state-schema";
|
|
10
|
+
export * from "./actions";
|
|
11
|
+
export * from "./events";
|
|
12
|
+
export * from "./autonomous";
|
|
13
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/runtime/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,mBAAmB,CAAC;AAClC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,wBAAwB,CAAC;AACvC,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
type InterfaceName = string;
|
|
2
|
+
type IntegrationName = string;
|
|
3
|
+
type InterfaceAction = string;
|
|
4
|
+
type IntegrationAction = string;
|
|
5
|
+
export type IntegrationInterfaceMappings = {
|
|
6
|
+
[Interface in InterfaceName]: {
|
|
7
|
+
actions: Record<`${IntegrationName}:${InterfaceAction}`, `${IntegrationName}:${IntegrationAction}`>;
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
export declare class InterfaceMappings {
|
|
11
|
+
private static mappings;
|
|
12
|
+
static registerMappings(mappings: IntegrationInterfaceMappings): void;
|
|
13
|
+
static getIntegrationAction(interfaceName: InterfaceName, actionName: InterfaceAction, integrationName: IntegrationName): string | undefined;
|
|
14
|
+
}
|
|
15
|
+
export {};
|
|
16
|
+
//# sourceMappingURL=interfaces.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../src/runtime/interfaces.ts"],"names":[],"mappings":"AAAA,KAAK,aAAa,GAAG,MAAM,CAAC;AAC5B,KAAK,eAAe,GAAG,MAAM,CAAC;AAC9B,KAAK,eAAe,GAAG,MAAM,CAAC;AAC9B,KAAK,iBAAiB,GAAG,MAAM,CAAC;AAEhC,MAAM,MAAM,4BAA4B,GAAG;KACxC,SAAS,IAAI,aAAa,GAAG;QAC5B,OAAO,EAAE,MAAM,CACb,GAAG,eAAe,IAAI,eAAe,EAAE,EACvC,GAAG,eAAe,IAAI,iBAAiB,EAAE,CAC1C,CAAC;KACH;CACF,CAAC;AAEF,qBAAa,iBAAiB;IAC5B,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAoC;WAE7C,gBAAgB,CAAC,QAAQ,EAAE,4BAA4B;WAIvD,oBAAoB,CAChC,aAAa,EAAE,aAAa,EAC5B,UAAU,EAAE,eAAe,EAC3B,eAAe,EAAE,eAAe,GAC/B,MAAM,GAAG,SAAS;CAKtB"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Runtime Singletons
|
|
3
|
+
*
|
|
4
|
+
* This module provides a type-safe way to manage singleton instances across
|
|
5
|
+
* multiple imports and bundling contexts. Each singleton is stored in globalThis
|
|
6
|
+
* to ensure the same instance is shared even when the module is loaded multiple times.
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Get or create a singleton instance from globalThis
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* const state = getSingleton('__ADK_GLOBAL_STATE', () => ({
|
|
13
|
+
* initialized: false,
|
|
14
|
+
* projectPath: undefined,
|
|
15
|
+
* }));
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* const cache = getSingleton<Map<string, any>>('__ADK_GLOBAL_MY_CACHE', () => new Map());
|
|
19
|
+
*/
|
|
20
|
+
export declare function getSingleton<T>(key: `__ADK_GLOBAL_${string}`, factory: () => T): T;
|
|
21
|
+
//# sourceMappingURL=singletons.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"singletons.d.ts","sourceRoot":"","sources":["../../src/runtime/singletons.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH;;;;;;;;;;;GAWG;AACH,wBAAgB,YAAY,CAAC,CAAC,EAC5B,GAAG,EAAE,gBAAgB,MAAM,EAAE,EAC7B,OAAO,EAAE,MAAM,CAAC,GACf,CAAC,CAKH"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../src/runtime/state.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,IAAI,YAAY,EACxB,SAAS,IAAI,aAAa,EAC3B,MAAM,iBAAiB,CAAC;AAMzB,eAAO,MAAM,GAAG,EAAE;IAAE,KAAK,EAAE,YAAY,CAAA;CA0BtC,CAAC;AAEF,eAAO,MAAM,IAAI,EAAE;IAAE,KAAK,EAAE,aAAa,CAAA;CAqCxC,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
export declare const TrackedStateSchema: import("@bpinternal/zui").ZodObject<{
|
|
2
|
+
value: import("@bpinternal/zui").ZodAny;
|
|
3
|
+
location: import("@bpinternal/zui").ZodDiscriminatedUnion<"type", [import("@bpinternal/zui").ZodObject<{
|
|
4
|
+
type: import("@bpinternal/zui").ZodLiteral<"state">;
|
|
5
|
+
}, "strip", {
|
|
6
|
+
type: "state";
|
|
7
|
+
}, {
|
|
8
|
+
type: "state";
|
|
9
|
+
}>, import("@bpinternal/zui").ZodObject<{
|
|
10
|
+
type: import("@bpinternal/zui").ZodLiteral<"file">;
|
|
11
|
+
key: import("@bpinternal/zui").ZodString;
|
|
12
|
+
}, "strip", {
|
|
13
|
+
type: "file";
|
|
14
|
+
key: string;
|
|
15
|
+
}, {
|
|
16
|
+
type: "file";
|
|
17
|
+
key: string;
|
|
18
|
+
}>]>;
|
|
19
|
+
}, "strip", {
|
|
20
|
+
location: {
|
|
21
|
+
type: "state";
|
|
22
|
+
} | {
|
|
23
|
+
type: "file";
|
|
24
|
+
key: string;
|
|
25
|
+
};
|
|
26
|
+
value?: any;
|
|
27
|
+
}, {
|
|
28
|
+
location: {
|
|
29
|
+
type: "state";
|
|
30
|
+
} | {
|
|
31
|
+
type: "file";
|
|
32
|
+
key: string;
|
|
33
|
+
};
|
|
34
|
+
value?: any;
|
|
35
|
+
}>;
|
|
36
|
+
//# sourceMappingURL=tracked-state-schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tracked-state-schema.d.ts","sourceRoot":"","sources":["../../src/runtime/tracked-state-schema.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAM7B,CAAC"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { Client } from "@botpress/client";
|
|
2
|
+
import { output } from "@botpress/sdk";
|
|
3
|
+
import { ZuiType } from "../types";
|
|
4
|
+
export declare const BUILT_IN_STATES: {
|
|
5
|
+
user: string;
|
|
6
|
+
conversation: string;
|
|
7
|
+
bot: string;
|
|
8
|
+
workflowState: string;
|
|
9
|
+
workflowSteps: string;
|
|
10
|
+
};
|
|
11
|
+
export declare class TrackedState<Schema extends ZuiType = ZuiType> {
|
|
12
|
+
type: "conversation" | "user" | "bot" | "workflow";
|
|
13
|
+
id: string;
|
|
14
|
+
name: string;
|
|
15
|
+
state: Schema;
|
|
16
|
+
client: Client;
|
|
17
|
+
value: Schema extends ZuiType ? output<Schema> | undefined : never | undefined;
|
|
18
|
+
private _lastSavedHash;
|
|
19
|
+
private _isDirty;
|
|
20
|
+
private _loaded;
|
|
21
|
+
private _saving;
|
|
22
|
+
private _saveAgain;
|
|
23
|
+
private _saveAgainCount;
|
|
24
|
+
private static _savingAll;
|
|
25
|
+
private static _saveAllAgain;
|
|
26
|
+
private static _saveAllCount;
|
|
27
|
+
private constructor();
|
|
28
|
+
static create<T extends ZuiType>(props: {
|
|
29
|
+
type: "conversation" | "user" | "bot" | "workflow";
|
|
30
|
+
id: string;
|
|
31
|
+
schema: T;
|
|
32
|
+
client: Client;
|
|
33
|
+
name: string;
|
|
34
|
+
}): TrackedState<T>;
|
|
35
|
+
static saveAllDirty(): Promise<void>;
|
|
36
|
+
static loadAll(): Promise<void>;
|
|
37
|
+
static unloadAll(): void;
|
|
38
|
+
load(force?: boolean): Promise<void>;
|
|
39
|
+
save(): Promise<void>;
|
|
40
|
+
/**
|
|
41
|
+
* Check if the state has been modified since last save/load
|
|
42
|
+
* Uses a fast hash comparison to detect changes
|
|
43
|
+
*/
|
|
44
|
+
isDirty(): boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Mark the state as dirty (modified)
|
|
47
|
+
* Useful when you know the state changed without checking
|
|
48
|
+
*/
|
|
49
|
+
markDirty(): void;
|
|
50
|
+
/**
|
|
51
|
+
* Calculate a fast hash of the value for change detection
|
|
52
|
+
* Uses crypto hash for better performance with large objects
|
|
53
|
+
*/
|
|
54
|
+
private calculateHash;
|
|
55
|
+
get diff(): string;
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=tracked-state.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tracked-state.d.ts","sourceRoot":"","sources":["../../src/runtime/tracked-state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,OAAO,EAAE,MAAM,EAAK,MAAM,eAAe,CAAC;AAQ1C,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAenC,eAAO,MAAM,eAAe;;;;;;CAM3B,CAAC;AAEF,qBAAa,YAAY,CAAC,MAAM,SAAS,OAAO,GAAG,OAAO;IACxD,IAAI,EAAE,cAAc,GAAG,MAAM,GAAG,KAAK,GAAG,UAAU,CAAC;IACnD,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAG,MAAM,SAAS,OAAO,GAC1B,MAAM,CAAC,MAAM,CAAC,GAAG,SAAS,GAC1B,KAAK,GAAG,SAAS,CAAC;IAEtB,OAAO,CAAC,cAAc,CAAuB;IAC7C,OAAO,CAAC,QAAQ,CAAkB;IAClC,OAAO,CAAC,OAAO,CAAkB;IAEjC,OAAO,CAAC,OAAO,CAAkB;IACjC,OAAO,CAAC,UAAU,CAAkB;IACpC,OAAO,CAAC,eAAe,CAAa;IAEpC,OAAO,CAAC,MAAM,CAAC,UAAU,CAAkB;IAC3C,OAAO,CAAC,MAAM,CAAC,aAAa,CAAkB;IAC9C,OAAO,CAAC,MAAM,CAAC,aAAa,CAAa;IAEzC,OAAO;WAcO,MAAM,CAAC,CAAC,SAAS,OAAO,EAAE,KAAK,EAAE;QAC7C,IAAI,EAAE,cAAc,GAAG,MAAM,GAAG,KAAK,GAAG,UAAU,CAAC;QACnD,EAAE,EAAE,MAAM,CAAC;QACX,MAAM,EAAE,CAAC,CAAC;QACV,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC;KACd,GAAG,YAAY,CAAC,CAAC,CAAC;WAoBC,YAAY;WAkCZ,OAAO;WAuCb,SAAS;IAIV,IAAI,CAAC,KAAK,GAAE,OAAe;IAsF3B,IAAI;IAmHjB;;;OAGG;IACI,OAAO,IAAI,OAAO;IAazB;;;OAGG;IACI,SAAS,IAAI,IAAI;IAIxB;;;OAGG;IACH,OAAO,CAAC,aAAa;IAyBrB,IAAW,IAAI,IAAI,MAAM,CAGxB;CACF"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Workflow } from "../../primitives";
|
|
2
|
+
/**
|
|
3
|
+
* Registry of built-in workflows that are automatically included in every agent
|
|
4
|
+
* These workflows are defined in the runtime and don't need to be created by users
|
|
5
|
+
*/
|
|
6
|
+
export declare const BuiltInWorkflows: Record<string, Workflow<any>>;
|
|
7
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/runtime/workflows/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAG5C;;;GAGG;AACH,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAC,GAAG,CAAC,CAE1D,CAAC"}
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { BaseWorkflow } from "../../primitives/workflow";
|
|
2
|
+
/**
|
|
3
|
+
* Built-in workflow for orchestrating knowledge base data source synchronization
|
|
4
|
+
* This workflow triggers sync workflows for all data sources in a knowledge base
|
|
5
|
+
*/
|
|
6
|
+
export declare const KnowledgeIndexingWorkflow: BaseWorkflow<"builtin_knowledge_indexing", import("@bpinternal/zui").ZodObject<{
|
|
7
|
+
kbName: import("@bpinternal/zui").ZodString;
|
|
8
|
+
force: import("@bpinternal/zui").ZodDefault<import("@bpinternal/zui").ZodOptional<import("@bpinternal/zui").ZodBoolean>>;
|
|
9
|
+
}, "strip", {
|
|
10
|
+
kbName: string;
|
|
11
|
+
force: boolean;
|
|
12
|
+
}, {
|
|
13
|
+
kbName: string;
|
|
14
|
+
force?: boolean | undefined;
|
|
15
|
+
}>, import("@bpinternal/zui").ZodObject<{
|
|
16
|
+
processed: import("@bpinternal/zui").ZodDefault<import("@bpinternal/zui").ZodNumber>;
|
|
17
|
+
added: import("@bpinternal/zui").ZodDefault<import("@bpinternal/zui").ZodArray<import("@bpinternal/zui").ZodObject<{
|
|
18
|
+
file: import("@bpinternal/zui").ZodString;
|
|
19
|
+
name: import("@bpinternal/zui").ZodString;
|
|
20
|
+
hash: import("@bpinternal/zui").ZodString;
|
|
21
|
+
size: import("@bpinternal/zui").ZodNumber;
|
|
22
|
+
}, "strip", {
|
|
23
|
+
name: string;
|
|
24
|
+
size: number;
|
|
25
|
+
hash: string;
|
|
26
|
+
file: string;
|
|
27
|
+
}, {
|
|
28
|
+
name: string;
|
|
29
|
+
size: number;
|
|
30
|
+
hash: string;
|
|
31
|
+
file: string;
|
|
32
|
+
}>, "many">>;
|
|
33
|
+
updated: import("@bpinternal/zui").ZodDefault<import("@bpinternal/zui").ZodArray<import("@bpinternal/zui").ZodObject<{
|
|
34
|
+
file: import("@bpinternal/zui").ZodString;
|
|
35
|
+
name: import("@bpinternal/zui").ZodString;
|
|
36
|
+
hash: import("@bpinternal/zui").ZodString;
|
|
37
|
+
size: import("@bpinternal/zui").ZodNumber;
|
|
38
|
+
}, "strip", {
|
|
39
|
+
name: string;
|
|
40
|
+
size: number;
|
|
41
|
+
hash: string;
|
|
42
|
+
file: string;
|
|
43
|
+
}, {
|
|
44
|
+
name: string;
|
|
45
|
+
size: number;
|
|
46
|
+
hash: string;
|
|
47
|
+
file: string;
|
|
48
|
+
}>, "many">>;
|
|
49
|
+
deleted: import("@bpinternal/zui").ZodDefault<import("@bpinternal/zui").ZodArray<import("@bpinternal/zui").ZodObject<{
|
|
50
|
+
file: import("@bpinternal/zui").ZodString;
|
|
51
|
+
name: import("@bpinternal/zui").ZodString;
|
|
52
|
+
hash: import("@bpinternal/zui").ZodString;
|
|
53
|
+
size: import("@bpinternal/zui").ZodNumber;
|
|
54
|
+
}, "strip", {
|
|
55
|
+
name: string;
|
|
56
|
+
size: number;
|
|
57
|
+
hash: string;
|
|
58
|
+
file: string;
|
|
59
|
+
}, {
|
|
60
|
+
name: string;
|
|
61
|
+
size: number;
|
|
62
|
+
hash: string;
|
|
63
|
+
file: string;
|
|
64
|
+
}>, "many">>;
|
|
65
|
+
errors: import("@bpinternal/zui").ZodDefault<import("@bpinternal/zui").ZodArray<import("@bpinternal/zui").ZodString, "many">>;
|
|
66
|
+
}, "strip", {
|
|
67
|
+
processed: number;
|
|
68
|
+
added: {
|
|
69
|
+
name: string;
|
|
70
|
+
size: number;
|
|
71
|
+
hash: string;
|
|
72
|
+
file: string;
|
|
73
|
+
}[];
|
|
74
|
+
updated: {
|
|
75
|
+
name: string;
|
|
76
|
+
size: number;
|
|
77
|
+
hash: string;
|
|
78
|
+
file: string;
|
|
79
|
+
}[];
|
|
80
|
+
deleted: {
|
|
81
|
+
name: string;
|
|
82
|
+
size: number;
|
|
83
|
+
hash: string;
|
|
84
|
+
file: string;
|
|
85
|
+
}[];
|
|
86
|
+
errors: string[];
|
|
87
|
+
}, {
|
|
88
|
+
processed?: number | undefined;
|
|
89
|
+
added?: {
|
|
90
|
+
name: string;
|
|
91
|
+
size: number;
|
|
92
|
+
hash: string;
|
|
93
|
+
file: string;
|
|
94
|
+
}[] | undefined;
|
|
95
|
+
updated?: {
|
|
96
|
+
name: string;
|
|
97
|
+
size: number;
|
|
98
|
+
hash: string;
|
|
99
|
+
file: string;
|
|
100
|
+
}[] | undefined;
|
|
101
|
+
deleted?: {
|
|
102
|
+
name: string;
|
|
103
|
+
size: number;
|
|
104
|
+
hash: string;
|
|
105
|
+
file: string;
|
|
106
|
+
}[] | undefined;
|
|
107
|
+
errors?: string[] | undefined;
|
|
108
|
+
}>, any, Record<string, import("../../types").ZuiType>>;
|
|
109
|
+
//# sourceMappingURL=knowledge-indexing.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"knowledge-indexing.d.ts","sourceRoot":"","sources":["../../../src/runtime/workflows/knowledge-indexing.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAQzD;;;GAGG;AACH,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uDA0DpC,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module @botpress/runtime/runtime
|
|
3
|
+
* @description This module is the main entry point for running a Botpress agent built with the ADK from the `@botpress/sdk` package.
|
|
4
|
+
* @note This module is intended for use only within the Botpress ADK monorepo, mainly auto-generated code in the `./.adk` folder of a bot project.
|
|
5
|
+
* @usage
|
|
6
|
+
* import { setup } from "@botpress/runtime/runtime"
|
|
7
|
+
* setup(bot) // where `bot` is provided by the Botpress SDK
|
|
8
|
+
*/
|
|
9
|
+
import "./globals";
|
|
10
|
+
import "./environment";
|
|
11
|
+
import "./telemetry/tracing";
|
|
12
|
+
export { z } from "@botpress/sdk";
|
|
13
|
+
export * from "./primitives";
|
|
14
|
+
export * from "./runtime/index";
|
|
15
|
+
export * from "./utilities/trigger-tags";
|
|
16
|
+
export * from "./types";
|
|
17
|
+
export * from "./errors";
|
|
18
|
+
export { bot, user } from "./runtime/state";
|
|
19
|
+
export { agentRegistry } from "./runtime/agent-registry";
|
|
20
|
+
export { defineConfig } from "./define-config";
|
|
21
|
+
export { initialize, register, registerIntegration } from "./runtime/adk";
|
|
22
|
+
//# sourceMappingURL=runtime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../src/runtime.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAKH,OAAO,WAAW,CAAC;AACnB,OAAO,eAAe,CAAC;AACvB,OAAO,qBAAqB,CAAC;AAW7B,OAAO,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAElC,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AAEzB,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE/C,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC"}
|