initial refactor

This commit is contained in:
dswbx
2025-06-21 13:35:58 +02:00
parent b2086c4da7
commit 42edce904f
93 changed files with 1021 additions and 1216 deletions
+5 -6
View File
@@ -1,7 +1,6 @@
import { Flow } from "../../flows/Flow";
import { Task, dynamic } from "../Task";
import * as tbbox from "@sinclair/typebox";
const { Type } = tbbox;
import { s } from "core/object/schema";
export class SubFlowTask<Output extends Record<string, any>> extends Task<
typeof SubFlowTask.schema,
@@ -9,10 +8,10 @@ export class SubFlowTask<Output extends Record<string, any>> extends Task<
> {
type = "subflow";
static override schema = Type.Object({
flow: Type.Any(),
input: Type.Optional(dynamic(Type.Any(), JSON.parse)),
loop: Type.Optional(Type.Boolean()),
static override schema = s.strictObject({
flow: s.any(),
input: dynamic(s.any(), JSON.parse).optional(),
loop: s.boolean().optional(),
});
async execute() {