@gobing-ai/ts-dual-workflow-engine 0.4.1 → 0.4.3
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/config.d.ts +15 -0
- package/dist/config.d.ts.map +1 -1
- package/package.json +4 -4
- package/src/config.ts +15 -1
package/dist/config.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type StructuredConfigLoadOptions } from '@gobing-ai/ts-runtime';
|
|
1
2
|
import type { WorkflowDef } from './types';
|
|
2
3
|
/** Loading options for {@link loadWorkflowDef}. */
|
|
3
4
|
export interface WorkflowLoadOptions {
|
|
@@ -5,6 +6,20 @@ export interface WorkflowLoadOptions {
|
|
|
5
6
|
validateSchema?: boolean;
|
|
6
7
|
/** Optional fetch implementation for remote HTTP(S) schema refs. */
|
|
7
8
|
fetch?: (input: string) => Promise<Response>;
|
|
9
|
+
/**
|
|
10
|
+
* Module resolver for bare package-specifier `$schema` refs (e.g.
|
|
11
|
+
* `@scope/pkg/schemas/x.json`). Defaults to `Bun.resolveSync`. Inject this when a
|
|
12
|
+
* bundled-config `$schema` must resolve without reaching `node_modules` — e.g. a
|
|
13
|
+
* `bun --compile` binary, or a validate call running from a cwd outside the package
|
|
14
|
+
* tree (where `Bun.resolveSync` cannot find the owning package).
|
|
15
|
+
*/
|
|
16
|
+
resolve?: StructuredConfigLoadOptions['resolve'];
|
|
17
|
+
/**
|
|
18
|
+
* File system used to read the config and local/embedded schema files. Defaults to
|
|
19
|
+
* the Node file system. Pair with {@link WorkflowLoadOptions.resolve} to serve schema
|
|
20
|
+
* text from an in-memory map instead of disk.
|
|
21
|
+
*/
|
|
22
|
+
fileSystem?: StructuredConfigLoadOptions['fileSystem'];
|
|
8
23
|
}
|
|
9
24
|
/** Load a workflow definition from YAML or JSON text. */
|
|
10
25
|
export declare function loadWorkflowDefFromText(text: string, source?: string): WorkflowDef;
|
package/dist/config.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAyC,KAAK,2BAA2B,EAAE,MAAM,uBAAuB,CAAC;AAIhH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAE3C,mDAAmD;AACnD,MAAM,WAAW,mBAAmB;IAChC,mFAAmF;IACnF,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,oEAAoE;IACpE,KAAK,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAC;IAC7C;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,2BAA2B,CAAC,SAAS,CAAC,CAAC;IACjD;;;;OAIG;IACH,UAAU,CAAC,EAAE,2BAA2B,CAAC,YAAY,CAAC,CAAC;CAC1D;AAED,yDAAyD;AACzD,wBAAgB,uBAAuB,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,SAAa,GAAG,WAAW,CAGtF;AAED,yDAAyD;AACzD,wBAAsB,eAAe,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,GAAE,mBAAwB,GAAG,OAAO,CAAC,WAAW,CAAC,CAE3G;AAED,0EAA0E;AAC1E,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,WAAW,GAAG,IAAI,CAM/D"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gobing-ai/ts-dual-workflow-engine",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.3",
|
|
4
4
|
"description": "@gobing-ai/ts-dual-workflow-engine — State-machine and transition-flow workflow runtime.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"typescript",
|
|
@@ -48,9 +48,9 @@
|
|
|
48
48
|
"release": "echo 'Manual publish is disabled. Releases go through GitHub Actions via Trusted Publishing — push a tag: git tag @gobing-ai/ts-dual-workflow-engine-v<version> && git push --tags' && exit 1"
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
|
-
"@gobing-ai/ts-db": "^0.4.
|
|
52
|
-
"@gobing-ai/ts-infra": "^0.4.
|
|
53
|
-
"@gobing-ai/ts-runtime": "^0.4.
|
|
51
|
+
"@gobing-ai/ts-db": "^0.4.3",
|
|
52
|
+
"@gobing-ai/ts-infra": "^0.4.3",
|
|
53
|
+
"@gobing-ai/ts-runtime": "^0.4.3",
|
|
54
54
|
"zod": "^4.1.0"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
package/src/config.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { loadStructuredConfig, parseYamlObject } from '@gobing-ai/ts-runtime';
|
|
1
|
+
import { loadStructuredConfig, parseYamlObject, type StructuredConfigLoadOptions } from '@gobing-ai/ts-runtime';
|
|
2
2
|
import { WorkflowValidationError } from './errors';
|
|
3
3
|
import { RUNTIME_BUILTIN_KEYS } from './run-lifecycle';
|
|
4
4
|
import { StateMachineWorkflowDefSchema, TransitionFlowWorkflowDefSchema } from './schema';
|
|
@@ -10,6 +10,20 @@ export interface WorkflowLoadOptions {
|
|
|
10
10
|
validateSchema?: boolean;
|
|
11
11
|
/** Optional fetch implementation for remote HTTP(S) schema refs. */
|
|
12
12
|
fetch?: (input: string) => Promise<Response>;
|
|
13
|
+
/**
|
|
14
|
+
* Module resolver for bare package-specifier `$schema` refs (e.g.
|
|
15
|
+
* `@scope/pkg/schemas/x.json`). Defaults to `Bun.resolveSync`. Inject this when a
|
|
16
|
+
* bundled-config `$schema` must resolve without reaching `node_modules` — e.g. a
|
|
17
|
+
* `bun --compile` binary, or a validate call running from a cwd outside the package
|
|
18
|
+
* tree (where `Bun.resolveSync` cannot find the owning package).
|
|
19
|
+
*/
|
|
20
|
+
resolve?: StructuredConfigLoadOptions['resolve'];
|
|
21
|
+
/**
|
|
22
|
+
* File system used to read the config and local/embedded schema files. Defaults to
|
|
23
|
+
* the Node file system. Pair with {@link WorkflowLoadOptions.resolve} to serve schema
|
|
24
|
+
* text from an in-memory map instead of disk.
|
|
25
|
+
*/
|
|
26
|
+
fileSystem?: StructuredConfigLoadOptions['fileSystem'];
|
|
13
27
|
}
|
|
14
28
|
|
|
15
29
|
/** Load a workflow definition from YAML or JSON text. */
|