@workglow/test 0.0.52
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/LICENSE +201 -0
- package/README.md +87 -0
- package/dist/binding/FsFolderTaskGraphRepository.d.ts +15 -0
- package/dist/binding/FsFolderTaskGraphRepository.d.ts.map +1 -0
- package/dist/binding/FsFolderTaskOutputRepository.d.ts +15 -0
- package/dist/binding/FsFolderTaskOutputRepository.d.ts.map +1 -0
- package/dist/binding/InMemoryJobQueue.d.ts +11 -0
- package/dist/binding/InMemoryJobQueue.d.ts.map +1 -0
- package/dist/binding/InMemoryTaskGraphRepository.d.ts +15 -0
- package/dist/binding/InMemoryTaskGraphRepository.d.ts.map +1 -0
- package/dist/binding/InMemoryTaskOutputRepository.d.ts +15 -0
- package/dist/binding/InMemoryTaskOutputRepository.d.ts.map +1 -0
- package/dist/binding/IndexedDbJobQueue.d.ts +11 -0
- package/dist/binding/IndexedDbJobQueue.d.ts.map +1 -0
- package/dist/binding/IndexedDbTaskGraphRepository.d.ts +15 -0
- package/dist/binding/IndexedDbTaskGraphRepository.d.ts.map +1 -0
- package/dist/binding/IndexedDbTaskOutputRepository.d.ts +15 -0
- package/dist/binding/IndexedDbTaskOutputRepository.d.ts.map +1 -0
- package/dist/binding/PostgresJobQueue.d.ts +11 -0
- package/dist/binding/PostgresJobQueue.d.ts.map +1 -0
- package/dist/binding/PostgresTaskGraphRepository.d.ts +16 -0
- package/dist/binding/PostgresTaskGraphRepository.d.ts.map +1 -0
- package/dist/binding/PostgresTaskOutputRepository.d.ts +16 -0
- package/dist/binding/PostgresTaskOutputRepository.d.ts.map +1 -0
- package/dist/binding/SqliteJobQueue.d.ts +11 -0
- package/dist/binding/SqliteJobQueue.d.ts.map +1 -0
- package/dist/binding/SqliteTaskGraphRepository.d.ts +15 -0
- package/dist/binding/SqliteTaskGraphRepository.d.ts.map +1 -0
- package/dist/binding/SqliteTaskOutputRepository.d.ts +15 -0
- package/dist/binding/SqliteTaskOutputRepository.d.ts.map +1 -0
- package/dist/browser.d.ts +11 -0
- package/dist/browser.d.ts.map +1 -0
- package/dist/browser.js +293 -0
- package/dist/browser.js.map +18 -0
- package/dist/bun.d.ts +7 -0
- package/dist/bun.d.ts.map +1 -0
- package/dist/bun.js +436 -0
- package/dist/bun.js.map +26 -0
- package/dist/common-server.d.ts +19 -0
- package/dist/common-server.d.ts.map +1 -0
- package/dist/common.d.ts +9 -0
- package/dist/common.d.ts.map +1 -0
- package/dist/node.d.ts +7 -0
- package/dist/node.d.ts.map +1 -0
- package/dist/node.js +435 -0
- package/dist/node.js.map +26 -0
- package/dist/samples/MediaPipeModelSamples.d.ts +2 -0
- package/dist/samples/MediaPipeModelSamples.d.ts.map +1 -0
- package/dist/samples/ONNXModelSamples.d.ts +4 -0
- package/dist/samples/ONNXModelSamples.d.ts.map +1 -0
- package/dist/samples/index.d.ts +10 -0
- package/dist/samples/index.d.ts.map +1 -0
- package/dist/test/ai-model/InMemoryModelRepository.test.d.ts +7 -0
- package/dist/test/ai-model/InMemoryModelRepository.test.d.ts.map +1 -0
- package/dist/test/ai-model/IndexedDbModelRepository.test.d.ts +7 -0
- package/dist/test/ai-model/IndexedDbModelRepository.test.d.ts.map +1 -0
- package/dist/test/ai-model/PostgresModelRepository.test.d.ts +7 -0
- package/dist/test/ai-model/PostgresModelRepository.test.d.ts.map +1 -0
- package/dist/test/ai-model/SqliteModelRepository.test.d.ts +7 -0
- package/dist/test/ai-model/SqliteModelRepository.test.d.ts.map +1 -0
- package/dist/test/ai-model/genericModelRepositoryTests.d.ts +8 -0
- package/dist/test/ai-model/genericModelRepositoryTests.d.ts.map +1 -0
- package/dist/test/ai-provider/AiProviderRegistry.test.d.ts +7 -0
- package/dist/test/ai-provider/AiProviderRegistry.test.d.ts.map +1 -0
- package/dist/test/ai-provider/HFTransformersBinding.test.d.ts +7 -0
- package/dist/test/ai-provider/HFTransformersBinding.test.d.ts.map +1 -0
- package/dist/test/ai-provider/TfMediaPipeBinding.test.d.ts +7 -0
- package/dist/test/ai-provider/TfMediaPipeBinding.test.d.ts.map +1 -0
- package/dist/test/helpers/SupabaseMockClient.d.ts +12 -0
- package/dist/test/helpers/SupabaseMockClient.d.ts.map +1 -0
- package/dist/test/job-queue/InMemoryJobQueue.test.d.ts +7 -0
- package/dist/test/job-queue/InMemoryJobQueue.test.d.ts.map +1 -0
- package/dist/test/job-queue/IndexedDbJobQueue.test.d.ts +7 -0
- package/dist/test/job-queue/IndexedDbJobQueue.test.d.ts.map +1 -0
- package/dist/test/job-queue/PostgresJobQueue.test.d.ts +7 -0
- package/dist/test/job-queue/PostgresJobQueue.test.d.ts.map +1 -0
- package/dist/test/job-queue/SqliteJobQueue.test.d.ts +7 -0
- package/dist/test/job-queue/SqliteJobQueue.test.d.ts.map +1 -0
- package/dist/test/job-queue/SupabaseJobQueue.test.d.ts +7 -0
- package/dist/test/job-queue/SupabaseJobQueue.test.d.ts.map +1 -0
- package/dist/test/job-queue/genericJobQueueTests.d.ts +18 -0
- package/dist/test/job-queue/genericJobQueueTests.d.ts.map +1 -0
- package/dist/test/storage-kv/FsFolderJsonKvRepository.test.d.ts +7 -0
- package/dist/test/storage-kv/FsFolderJsonKvRepository.test.d.ts.map +1 -0
- package/dist/test/storage-kv/FsFolderKvRepository.test.d.ts +7 -0
- package/dist/test/storage-kv/FsFolderKvRepository.test.d.ts.map +1 -0
- package/dist/test/storage-kv/InMemoryKvRepository.test.d.ts +7 -0
- package/dist/test/storage-kv/InMemoryKvRepository.test.d.ts.map +1 -0
- package/dist/test/storage-kv/IndexedDbKvRepository.test.d.ts +7 -0
- package/dist/test/storage-kv/IndexedDbKvRepository.test.d.ts.map +1 -0
- package/dist/test/storage-kv/PostgresKvRepository.test.d.ts +7 -0
- package/dist/test/storage-kv/PostgresKvRepository.test.d.ts.map +1 -0
- package/dist/test/storage-kv/SqliteKvRepository.test.d.ts +7 -0
- package/dist/test/storage-kv/SqliteKvRepository.test.d.ts.map +1 -0
- package/dist/test/storage-kv/SupabaseKvRepository.test.d.ts +7 -0
- package/dist/test/storage-kv/SupabaseKvRepository.test.d.ts.map +1 -0
- package/dist/test/storage-kv/genericKvRepositoryTests.d.ts +9 -0
- package/dist/test/storage-kv/genericKvRepositoryTests.d.ts.map +1 -0
- package/dist/test/storage-tabular/CachedTabularRepository.test.d.ts +7 -0
- package/dist/test/storage-tabular/CachedTabularRepository.test.d.ts.map +1 -0
- package/dist/test/storage-tabular/FsFolderTabularRepository.test.d.ts +7 -0
- package/dist/test/storage-tabular/FsFolderTabularRepository.test.d.ts.map +1 -0
- package/dist/test/storage-tabular/InMemoryTabularRepository.test.d.ts +7 -0
- package/dist/test/storage-tabular/InMemoryTabularRepository.test.d.ts.map +1 -0
- package/dist/test/storage-tabular/IndexedDbTabularRepository.test.d.ts +7 -0
- package/dist/test/storage-tabular/IndexedDbTabularRepository.test.d.ts.map +1 -0
- package/dist/test/storage-tabular/PostgresTabularRepository.test.d.ts +7 -0
- package/dist/test/storage-tabular/PostgresTabularRepository.test.d.ts.map +1 -0
- package/dist/test/storage-tabular/SqliteTabularRepository.test.d.ts +7 -0
- package/dist/test/storage-tabular/SqliteTabularRepository.test.d.ts.map +1 -0
- package/dist/test/storage-tabular/SupabaseTabularRepository.test.d.ts +7 -0
- package/dist/test/storage-tabular/SupabaseTabularRepository.test.d.ts.map +1 -0
- package/dist/test/storage-tabular/genericTabularRepositoryTests.d.ts +90 -0
- package/dist/test/storage-tabular/genericTabularRepositoryTests.d.ts.map +1 -0
- package/dist/test/storage-util/IndexedDbTable.migration.test.d.ts +7 -0
- package/dist/test/storage-util/IndexedDbTable.migration.test.d.ts.map +1 -0
- package/dist/test/task/ArrayTask.test.d.ts +7 -0
- package/dist/test/task/ArrayTask.test.d.ts.map +1 -0
- package/dist/test/task/ConditionalTask.test.d.ts +7 -0
- package/dist/test/task/ConditionalTask.test.d.ts.map +1 -0
- package/dist/test/task/DelayTask.test.d.ts +7 -0
- package/dist/test/task/DelayTask.test.d.ts.map +1 -0
- package/dist/test/task/FetchTask.test.d.ts +7 -0
- package/dist/test/task/FetchTask.test.d.ts.map +1 -0
- package/dist/test/task/GraphAsTask.test.d.ts +2 -0
- package/dist/test/task/GraphAsTask.test.d.ts.map +1 -0
- package/dist/test/task/JavaScriptTask.test.d.ts +7 -0
- package/dist/test/task/JavaScriptTask.test.d.ts.map +1 -0
- package/dist/test/task/LambdaTask.test.d.ts +7 -0
- package/dist/test/task/LambdaTask.test.d.ts.map +1 -0
- package/dist/test/task/OwnTask.test.d.ts +2 -0
- package/dist/test/task/OwnTask.test.d.ts.map +1 -0
- package/dist/test/task/SingleTask.test.d.ts +7 -0
- package/dist/test/task/SingleTask.test.d.ts.map +1 -0
- package/dist/test/task/TestTasks.d.ts +387 -0
- package/dist/test/task/TestTasks.d.ts.map +1 -0
- package/dist/test/task-graph/Pipeline.test.d.ts +7 -0
- package/dist/test/task-graph/Pipeline.test.d.ts.map +1 -0
- package/dist/test/task-graph/TaskGraph.test.d.ts +7 -0
- package/dist/test/task-graph/TaskGraph.test.d.ts.map +1 -0
- package/dist/test/task-graph/TaskGraphFormatSemantic.test.d.ts +7 -0
- package/dist/test/task-graph/TaskGraphFormatSemantic.test.d.ts.map +1 -0
- package/dist/test/task-graph/TaskGraphRunner.test.d.ts +7 -0
- package/dist/test/task-graph/TaskGraphRunner.test.d.ts.map +1 -0
- package/dist/test/task-graph/TaskSubGraphRunner.test.d.ts +7 -0
- package/dist/test/task-graph/TaskSubGraphRunner.test.d.ts.map +1 -0
- package/dist/test/task-graph/Workflow.test.d.ts +7 -0
- package/dist/test/task-graph/Workflow.test.d.ts.map +1 -0
- package/dist/test/task-graph-job-queue/InMemoryTaskGraphJobQueue.test.d.ts +7 -0
- package/dist/test/task-graph-job-queue/InMemoryTaskGraphJobQueue.test.d.ts.map +1 -0
- package/dist/test/task-graph-job-queue/IndexedDbTaskGraphJobQueue.test.d.ts +7 -0
- package/dist/test/task-graph-job-queue/IndexedDbTaskGraphJobQueue.test.d.ts.map +1 -0
- package/dist/test/task-graph-job-queue/SqliteTaskGraphJobQueue.test.d.ts +7 -0
- package/dist/test/task-graph-job-queue/SqliteTaskGraphJobQueue.test.d.ts.map +1 -0
- package/dist/test/task-graph-job-queue/genericTaskGraphJobQueueTests.d.ts +23 -0
- package/dist/test/task-graph-job-queue/genericTaskGraphJobQueueTests.d.ts.map +1 -0
- package/dist/test/task-graph-output-cache/FileTaskOutputRepository.test.d.ts +7 -0
- package/dist/test/task-graph-output-cache/FileTaskOutputRepository.test.d.ts.map +1 -0
- package/dist/test/task-graph-output-cache/InMemoryTaskOutputRepository.test.d.ts +7 -0
- package/dist/test/task-graph-output-cache/InMemoryTaskOutputRepository.test.d.ts.map +1 -0
- package/dist/test/task-graph-output-cache/IndexedDbTaskOutputRepository.test.d.ts +7 -0
- package/dist/test/task-graph-output-cache/IndexedDbTaskOutputRepository.test.d.ts.map +1 -0
- package/dist/test/task-graph-output-cache/SqliteTaskOutputRepository.test.d.ts +7 -0
- package/dist/test/task-graph-output-cache/SqliteTaskOutputRepository.test.d.ts.map +1 -0
- package/dist/test/task-graph-output-cache/genericTaskOutputRepositoryTests.d.ts +8 -0
- package/dist/test/task-graph-output-cache/genericTaskOutputRepositoryTests.d.ts.map +1 -0
- package/dist/test/task-graph-storage/FileTaskGraphRepository.test.d.ts +7 -0
- package/dist/test/task-graph-storage/FileTaskGraphRepository.test.d.ts.map +1 -0
- package/dist/test/task-graph-storage/InMemoryTaskGraphRepository.test.d.ts +7 -0
- package/dist/test/task-graph-storage/InMemoryTaskGraphRepository.test.d.ts.map +1 -0
- package/dist/test/task-graph-storage/IndexedDbTaskGraphRepository.test.d.ts +7 -0
- package/dist/test/task-graph-storage/IndexedDbTaskGraphRepository.test.d.ts.map +1 -0
- package/dist/test/task-graph-storage/SqliteTaskGraphRepository.test.d.ts +7 -0
- package/dist/test/task-graph-storage/SqliteTaskGraphRepository.test.d.ts.map +1 -0
- package/dist/test/task-graph-storage/genericTaskGraphRepositoryTests.d.ts +8 -0
- package/dist/test/task-graph-storage/genericTaskGraphRepositoryTests.d.ts.map +1 -0
- package/dist/test/util/EventEmitter.test.d.ts +7 -0
- package/dist/test/util/EventEmitter.test.d.ts.map +1 -0
- package/dist/test/util/SchemaUtils.test.d.ts +7 -0
- package/dist/test/util/SchemaUtils.test.d.ts.map +1 -0
- package/dist/test/util/arrayAsObjectProxy.test.d.ts +7 -0
- package/dist/test/util/arrayAsObjectProxy.test.d.ts.map +1 -0
- package/dist/test/util/compression.test.d.ts +7 -0
- package/dist/test/util/compression.test.d.ts.map +1 -0
- package/dist/test/util/directedAcyclicGraph.test.d.ts +2 -0
- package/dist/test/util/directedAcyclicGraph.test.d.ts.map +1 -0
- package/dist/test/util/directedGraph.test.d.ts +2 -0
- package/dist/test/util/directedGraph.test.d.ts.map +1 -0
- package/dist/test/util/graph.test.d.ts +5 -0
- package/dist/test/util/graph.test.d.ts.map +1 -0
- package/dist/test/util/readme.test.d.ts +2 -0
- package/dist/test/util/readme.test.d.ts.map +1 -0
- package/dist/types.d.ts +7 -0
- package/dist/types.d.ts.map +1 -0
- package/package.json +93 -0
- package/src/binding/README.md +76 -0
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2025 Steven Roussey <sroussey@gmail.com>
|
|
4
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
+
*/
|
|
6
|
+
import { TaskGraphRepository } from "@workglow/task-graph";
|
|
7
|
+
export declare function runGenericTaskGraphRepositoryTests(createRepository: () => Promise<TaskGraphRepository>): void;
|
|
8
|
+
//# sourceMappingURL=genericTaskGraphRepositoryTests.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"genericTaskGraphRepositoryTests.d.ts","sourceRoot":"","sources":["../../../src/test/task-graph-storage/genericTaskGraphRepositoryTests.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAGL,mBAAmB,EAGpB,MAAM,sBAAsB,CAAC;AAM9B,wBAAgB,kCAAkC,CAChD,gBAAgB,EAAE,MAAM,OAAO,CAAC,mBAAmB,CAAC,QA8DrD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EventEmitter.test.d.ts","sourceRoot":"","sources":["../../../src/test/util/EventEmitter.test.ts"],"names":[],"mappings":"AAAA;;;;GAIG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SchemaUtils.test.d.ts","sourceRoot":"","sources":["../../../src/test/util/SchemaUtils.test.ts"],"names":[],"mappings":"AAAA;;;;GAIG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"arrayAsObjectProxy.test.d.ts","sourceRoot":"","sources":["../../../src/test/util/arrayAsObjectProxy.test.ts"],"names":[],"mappings":"AAAA;;;;GAIG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"compression.test.d.ts","sourceRoot":"","sources":["../../../src/test/util/compression.test.ts"],"names":[],"mappings":"AAAA;;;;GAIG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"directedAcyclicGraph.test.d.ts","sourceRoot":"","sources":["../../../src/test/util/directedAcyclicGraph.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"directedGraph.test.d.ts","sourceRoot":"","sources":["../../../src/test/util/directedGraph.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export type HashInput = string | Uint8Array | ArrayBuffer;
|
|
2
|
+
export declare function hash(input: HashInput): string;
|
|
3
|
+
export declare const nodeIdentity: (n: any) => string;
|
|
4
|
+
export declare const edgeIdentity: (edge: any, node1Identity: any, node2Identity: any) => string;
|
|
5
|
+
//# sourceMappingURL=graph.test.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graph.test.d.ts","sourceRoot":"","sources":["../../../src/test/util/graph.test.ts"],"names":[],"mappings":"AAUA,MAAM,MAAM,SAAS,GAAG,MAAM,GAAG,UAAU,GAAG,WAAW,CAAC;AAE1D,wBAAgB,IAAI,CAAC,KAAK,EAAE,SAAS,GAAG,MAAM,CAY7C;AA8BD,eAAO,MAAM,YAAY,GAAI,GAAG,GAAG,WAA8C,CAAC;AAClF,eAAO,MAAM,YAAY,GAAI,MAAM,GAAG,EAAE,eAAe,GAAG,EAAE,eAAe,GAAG,WAG7E,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"readme.test.d.ts","sourceRoot":"","sources":["../../../src/test/util/readme.test.ts"],"names":[],"mappings":""}
|
package/dist/types.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,cAAc,iBAAiB,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@workglow/test",
|
|
3
|
+
"type": "module",
|
|
4
|
+
"version": "0.0.52",
|
|
5
|
+
"description": "Testing utilities and test suites for Workglow packages, providing comprehensive testing infrastructure.",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"watch": "concurrently -c 'auto' 'bun:watch-*'",
|
|
8
|
+
"watch-browser": "bun build --watch --no-clear-screen --target=browser --sourcemap=external --packages=external --outdir ./dist/ ./src/browser.ts",
|
|
9
|
+
"watch-node": "bun build --watch --no-clear-screen --target=node --sourcemap=external --packages=external --outdir ./dist/ ./src/node.ts",
|
|
10
|
+
"watch-bun": "bun build --watch --no-clear-screen --target=bun --sourcemap=external --packages=external --outdir ./dist/ ./src/bun.ts",
|
|
11
|
+
"watch-types": "tsc --watch --preserveWatchOutput",
|
|
12
|
+
"build-package": "bun run build-clean && concurrently -c 'auto' -n 'browser,node,bun,types' 'bun run build-browser' 'bun run build-node' 'bun run build-bun' 'bun run build-types'",
|
|
13
|
+
"build-clean": "rm -fr dist/*",
|
|
14
|
+
"build-browser": "bun build --target=browser --sourcemap=external --packages=external --outdir ./dist/ ./src/browser.ts",
|
|
15
|
+
"build-node": "bun build --target=node --sourcemap=external --packages=external --outdir ./dist/ ./src/node.ts",
|
|
16
|
+
"build-bun": "bun build --target=bun --sourcemap=external --packages=external --outdir ./dist/ ./src/bun.ts",
|
|
17
|
+
"build-types": "rm -f tsconfig.tsbuildinfo && tsc",
|
|
18
|
+
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
|
|
19
|
+
"test": "bun test",
|
|
20
|
+
"test-concurrently": "bash -c 'cmds=(); for d in ./src/test/*/; do cmds+=(\"cd $d && bun test\"); done; concurrently \"${cmds[@]}\"'"
|
|
21
|
+
},
|
|
22
|
+
"exports": {
|
|
23
|
+
".": {
|
|
24
|
+
"react-native": "./dist/browser.js",
|
|
25
|
+
"browser": "./dist/browser.js",
|
|
26
|
+
"bun": "./dist/bun.js",
|
|
27
|
+
"types": "./dist/types.d.ts",
|
|
28
|
+
"node": "./dist/node.js"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"files": [
|
|
32
|
+
"dist",
|
|
33
|
+
"src/**/*.md"
|
|
34
|
+
],
|
|
35
|
+
"peerDependencies": {
|
|
36
|
+
"@workglow/ai": "0.0.52",
|
|
37
|
+
"@workglow/ai-provider": "0.0.52",
|
|
38
|
+
"@workglow/job-queue": "0.0.52",
|
|
39
|
+
"@workglow/storage": "0.0.52",
|
|
40
|
+
"@workglow/task-graph": "0.0.52",
|
|
41
|
+
"@workglow/tasks": "0.0.52",
|
|
42
|
+
"@workglow/util": "0.0.52",
|
|
43
|
+
"@workglow/sqlite": "0.0.52",
|
|
44
|
+
"@electric-sql/pglite": "^0.3.11",
|
|
45
|
+
"pg": "^8.16.3",
|
|
46
|
+
"@supabase/supabase-js": "^2.84.0"
|
|
47
|
+
},
|
|
48
|
+
"peerDependenciesMeta": {
|
|
49
|
+
"@workglow/ai": {
|
|
50
|
+
"optional": false
|
|
51
|
+
},
|
|
52
|
+
"@workglow/ai-provider": {
|
|
53
|
+
"optional": false
|
|
54
|
+
},
|
|
55
|
+
"@workglow/job-queue": {
|
|
56
|
+
"optional": false
|
|
57
|
+
},
|
|
58
|
+
"@workglow/storage": {
|
|
59
|
+
"optional": false
|
|
60
|
+
},
|
|
61
|
+
"@workglow/task-graph": {
|
|
62
|
+
"optional": false
|
|
63
|
+
},
|
|
64
|
+
"@workglow/tasks": {
|
|
65
|
+
"optional": false
|
|
66
|
+
},
|
|
67
|
+
"@workglow/util": {
|
|
68
|
+
"optional": false
|
|
69
|
+
},
|
|
70
|
+
"@workglow/sqlite": {
|
|
71
|
+
"optional": false
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
"devDependencies": {
|
|
75
|
+
"@electric-sql/pglite": "^0.3.11",
|
|
76
|
+
"@workglow/ai": "0.0.52",
|
|
77
|
+
"@workglow/ai-provider": "0.0.52",
|
|
78
|
+
"@workglow/job-queue": "0.0.52",
|
|
79
|
+
"@workglow/sqlite": "0.0.52",
|
|
80
|
+
"@workglow/storage": "0.0.52",
|
|
81
|
+
"@workglow/task-graph": "0.0.52",
|
|
82
|
+
"@workglow/tasks": "0.0.52",
|
|
83
|
+
"@workglow/util": "0.0.52",
|
|
84
|
+
"@supabase/supabase-js": "^2.84.0",
|
|
85
|
+
"@types/pg": "^8.15.5",
|
|
86
|
+
"fake-indexeddb": "^6.2.4",
|
|
87
|
+
"pg": "^8.16.3",
|
|
88
|
+
"vitest": "^4.0.10"
|
|
89
|
+
},
|
|
90
|
+
"publishConfig": {
|
|
91
|
+
"access": "public"
|
|
92
|
+
}
|
|
93
|
+
}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# TaskGraph Storage Module Bindings
|
|
2
|
+
|
|
3
|
+
These are bindings for the task graph storage module for use in the test suite and getting started guides.
|
|
4
|
+
|
|
5
|
+
- [Task Output Repositories](#task-output-repositories)
|
|
6
|
+
- [Task Graph Repositories](#task-graph-repositories)
|
|
7
|
+
- [Testing](#testing)
|
|
8
|
+
- [Architecture Notes](#architecture-notes)
|
|
9
|
+
- [License](#license)
|
|
10
|
+
|
|
11
|
+
## Task Output Repositories
|
|
12
|
+
|
|
13
|
+
TaskOutputRepository is a repository for task caching.
|
|
14
|
+
|
|
15
|
+
Available Binding Implementations:
|
|
16
|
+
|
|
17
|
+
- **InMemoryTaskOutputRepository**: Volatile in-memory storage
|
|
18
|
+
- **FsFolderTaskOutputRepository**: File system storage
|
|
19
|
+
- **IndexedDbTaskOutputRepository**: IndexedDB storage
|
|
20
|
+
- **SqliteTaskOutputRepository**: SQLite storage
|
|
21
|
+
- **PostgresTaskOutputRepository**: PostgreSQL storage
|
|
22
|
+
|
|
23
|
+
All implementations extend `TaskOutputRepository` abstract class and provide:
|
|
24
|
+
|
|
25
|
+
- Task-type specific storage
|
|
26
|
+
- Event emitters for storage operations
|
|
27
|
+
|
|
28
|
+
```typescript
|
|
29
|
+
// Example usage
|
|
30
|
+
const outputRepo = new SqliteTaskOutputRepository(":memory:");
|
|
31
|
+
await outputRepo.saveOutput("MyTaskType", { param: "value" }, { result: "data" });
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Task Graph Repositories
|
|
35
|
+
|
|
36
|
+
TaskGraphRepository is a repository for task graphs themselves. It is used to save and load task graphs.
|
|
37
|
+
|
|
38
|
+
Available Binding Implementations:
|
|
39
|
+
|
|
40
|
+
- **InMemoryTaskGraphRepository**: Volatile in-memory storage (good for testing)
|
|
41
|
+
- **FsFolderTaskGraphRepository**: File system storage using JSON files
|
|
42
|
+
- **IndexedDbTaskGraphRepository**: Browser-based IndexedDB storage
|
|
43
|
+
- **SqliteTaskGraphRepository**: SQLite database storage
|
|
44
|
+
- **PostgresTaskGraphRepository**: PostgreSQL database storage
|
|
45
|
+
|
|
46
|
+
All implementations extend `TaskGraphRepository` class and provide storage for task graphs.
|
|
47
|
+
|
|
48
|
+
```typescript
|
|
49
|
+
// Example usage
|
|
50
|
+
const fsRepo = new FsFolderTaskGraphRepository("./storage");
|
|
51
|
+
const memoryRepo = new InMemoryTaskGraphRepository();
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
## Testing
|
|
55
|
+
|
|
56
|
+
Tests are written using Bun test runner. To run tests:
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
bun test
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
Tests include:
|
|
63
|
+
|
|
64
|
+
- Generic repository tests that run against all implementations
|
|
65
|
+
- Storage-specific test suites
|
|
66
|
+
|
|
67
|
+
## Architecture Notes
|
|
68
|
+
|
|
69
|
+
- All repositories use a TabularRepository pattern internally
|
|
70
|
+
- Schema definitions are centralized in `TaskGraphSchema`/`TaskOutputSchema`
|
|
71
|
+
- Primary key configurations are managed through `PrimaryKeyNames` constants
|
|
72
|
+
- Event emitters provide hooks for monitoring repository operations
|
|
73
|
+
|
|
74
|
+
## License
|
|
75
|
+
|
|
76
|
+
Apache 2.0 - See LICENSE file for details
|