@agentforge/patterns 0.16.79 → 0.16.81

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/index.d.cts CHANGED
@@ -81,15 +81,15 @@ declare const ToolResultSchema: z.ZodObject<{
81
81
  isDuplicate: z.ZodOptional<z.ZodBoolean>;
82
82
  }, "strip", z.ZodTypeAny, {
83
83
  toolCallId: string;
84
+ error?: string | undefined;
84
85
  timestamp?: number | undefined;
85
86
  result?: unknown;
86
- error?: string | undefined;
87
87
  isDuplicate?: boolean | undefined;
88
88
  }, {
89
89
  toolCallId: string;
90
+ error?: string | undefined;
90
91
  timestamp?: number | undefined;
91
92
  result?: unknown;
92
- error?: string | undefined;
93
93
  isDuplicate?: boolean | undefined;
94
94
  }>;
95
95
  type ToolResult = z.infer<typeof ToolResultSchema>;
@@ -158,15 +158,15 @@ declare const ReActState: _langchain_langgraph.AnnotationRoot<{
158
158
  }[], unknown>;
159
159
  observations: _langchain_langgraph.BaseChannel<{
160
160
  toolCallId: string;
161
+ error?: string | undefined;
161
162
  timestamp?: number | undefined;
162
163
  result?: unknown;
163
- error?: string | undefined;
164
164
  isDuplicate?: boolean | undefined;
165
165
  }[], {
166
166
  toolCallId: string;
167
+ error?: string | undefined;
167
168
  timestamp?: number | undefined;
168
169
  result?: unknown;
169
- error?: string | undefined;
170
170
  isDuplicate?: boolean | undefined;
171
171
  }[], unknown>;
172
172
  scratchpad: _langchain_langgraph.BaseChannel<{
@@ -644,6 +644,7 @@ declare const CompletedStepSchema: z.ZodObject<{
644
644
  */
645
645
  timestamp: z.ZodString;
646
646
  }, "strip", z.ZodTypeAny, {
647
+ success: boolean;
647
648
  timestamp: string;
648
649
  step: {
649
650
  id: string;
@@ -652,10 +653,10 @@ declare const CompletedStepSchema: z.ZodObject<{
652
653
  args?: Record<string, unknown> | undefined;
653
654
  dependencies?: string[] | undefined;
654
655
  };
655
- success: boolean;
656
- result?: unknown;
657
656
  error?: string | undefined;
657
+ result?: unknown;
658
658
  }, {
659
+ success: boolean;
659
660
  timestamp: string;
660
661
  step: {
661
662
  id: string;
@@ -664,9 +665,8 @@ declare const CompletedStepSchema: z.ZodObject<{
664
665
  args?: Record<string, unknown> | undefined;
665
666
  dependencies?: string[] | undefined;
666
667
  };
667
- success: boolean;
668
- result?: unknown;
669
668
  error?: string | undefined;
669
+ result?: unknown;
670
670
  }>;
671
671
  type CompletedStep = z.infer<typeof CompletedStepSchema>;
672
672
  /**
@@ -875,6 +875,7 @@ declare const PlanExecuteStateConfig: {
875
875
  error: z.ZodOptional<z.ZodString>;
876
876
  timestamp: z.ZodString;
877
877
  }, "strip", z.ZodTypeAny, {
878
+ success: boolean;
878
879
  timestamp: string;
879
880
  step: {
880
881
  id: string;
@@ -883,10 +884,10 @@ declare const PlanExecuteStateConfig: {
883
884
  args?: Record<string, unknown> | undefined;
884
885
  dependencies?: string[] | undefined;
885
886
  };
886
- success: boolean;
887
- result?: unknown;
888
887
  error?: string | undefined;
888
+ result?: unknown;
889
889
  }, {
890
+ success: boolean;
890
891
  timestamp: string;
891
892
  step: {
892
893
  id: string;
@@ -895,11 +896,11 @@ declare const PlanExecuteStateConfig: {
895
896
  args?: Record<string, unknown> | undefined;
896
897
  dependencies?: string[] | undefined;
897
898
  };
898
- success: boolean;
899
- result?: unknown;
900
899
  error?: string | undefined;
900
+ result?: unknown;
901
901
  }>, "many">;
902
902
  reducer: (left: CompletedStep[], right: CompletedStep[]) => {
903
+ success: boolean;
903
904
  timestamp: string;
904
905
  step: {
905
906
  id: string;
@@ -908,9 +909,8 @@ declare const PlanExecuteStateConfig: {
908
909
  args?: Record<string, unknown> | undefined;
909
910
  dependencies?: string[] | undefined;
910
911
  };
911
- success: boolean;
912
- result?: unknown;
913
912
  error?: string | undefined;
913
+ result?: unknown;
914
914
  }[];
915
915
  default: () => never[];
916
916
  description: string;
@@ -993,6 +993,7 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
993
993
  confidence?: number | undefined;
994
994
  } | undefined, unknown>;
995
995
  pastSteps: _langchain_langgraph.BaseChannel<{
996
+ success: boolean;
996
997
  timestamp: string;
997
998
  step: {
998
999
  id: string;
@@ -1001,10 +1002,10 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
1001
1002
  args?: Record<string, unknown> | undefined;
1002
1003
  dependencies?: string[] | undefined;
1003
1004
  };
1004
- success: boolean;
1005
- result?: unknown;
1006
1005
  error?: string | undefined;
1006
+ result?: unknown;
1007
1007
  }[], {
1008
+ success: boolean;
1008
1009
  timestamp: string;
1009
1010
  step: {
1010
1011
  id: string;
@@ -1013,12 +1014,11 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
1013
1014
  args?: Record<string, unknown> | undefined;
1014
1015
  dependencies?: string[] | undefined;
1015
1016
  };
1016
- success: boolean;
1017
- result?: unknown;
1018
1017
  error?: string | undefined;
1018
+ result?: unknown;
1019
1019
  }[], unknown>;
1020
1020
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1021
- status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", unknown>;
1021
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1022
1022
  response: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1023
1023
  error: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1024
1024
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
@@ -1253,6 +1253,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1253
1253
  confidence?: number | undefined;
1254
1254
  } | undefined;
1255
1255
  pastSteps: {
1256
+ success: boolean;
1256
1257
  timestamp: string;
1257
1258
  step: {
1258
1259
  id: string;
@@ -1261,12 +1262,11 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1261
1262
  args?: Record<string, unknown> | undefined;
1262
1263
  dependencies?: string[] | undefined;
1263
1264
  };
1264
- success: boolean;
1265
- result?: unknown;
1266
1265
  error?: string | undefined;
1266
+ result?: unknown;
1267
1267
  }[];
1268
1268
  currentStepIndex: number | undefined;
1269
- status: "failed" | "planning" | "executing" | "replanning" | "completed";
1269
+ status: "completed" | "failed" | "planning" | "executing" | "replanning";
1270
1270
  response: string | undefined;
1271
1271
  error: string | undefined;
1272
1272
  iteration: number;
@@ -1286,6 +1286,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1286
1286
  confidence?: number | undefined;
1287
1287
  } | undefined;
1288
1288
  pastSteps?: {
1289
+ success: boolean;
1289
1290
  timestamp: string;
1290
1291
  step: {
1291
1292
  id: string;
@@ -1294,12 +1295,11 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1294
1295
  args?: Record<string, unknown> | undefined;
1295
1296
  dependencies?: string[] | undefined;
1296
1297
  };
1297
- success: boolean;
1298
- result?: unknown;
1299
1298
  error?: string | undefined;
1299
+ result?: unknown;
1300
1300
  }[] | undefined;
1301
1301
  currentStepIndex?: number | undefined;
1302
- status?: "failed" | "planning" | "executing" | "replanning" | "completed" | undefined;
1302
+ status?: "completed" | "failed" | "planning" | "executing" | "replanning" | undefined;
1303
1303
  response?: string | undefined;
1304
1304
  error?: string | undefined;
1305
1305
  iteration?: number | undefined;
@@ -1330,6 +1330,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1330
1330
  confidence?: number | undefined;
1331
1331
  } | undefined, unknown>;
1332
1332
  pastSteps: _langchain_langgraph.BaseChannel<{
1333
+ success: boolean;
1333
1334
  timestamp: string;
1334
1335
  step: {
1335
1336
  id: string;
@@ -1338,10 +1339,10 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1338
1339
  args?: Record<string, unknown> | undefined;
1339
1340
  dependencies?: string[] | undefined;
1340
1341
  };
1341
- success: boolean;
1342
- result?: unknown;
1343
1342
  error?: string | undefined;
1343
+ result?: unknown;
1344
1344
  }[], {
1345
+ success: boolean;
1345
1346
  timestamp: string;
1346
1347
  step: {
1347
1348
  id: string;
@@ -1350,12 +1351,11 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1350
1351
  args?: Record<string, unknown> | undefined;
1351
1352
  dependencies?: string[] | undefined;
1352
1353
  };
1353
- success: boolean;
1354
- result?: unknown;
1355
1354
  error?: string | undefined;
1355
+ result?: unknown;
1356
1356
  }[], unknown>;
1357
1357
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1358
- status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", unknown>;
1358
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1359
1359
  response: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1360
1360
  error: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1361
1361
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
@@ -1386,6 +1386,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1386
1386
  confidence?: number | undefined;
1387
1387
  } | undefined, unknown>;
1388
1388
  pastSteps: _langchain_langgraph.BaseChannel<{
1389
+ success: boolean;
1389
1390
  timestamp: string;
1390
1391
  step: {
1391
1392
  id: string;
@@ -1394,10 +1395,10 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1394
1395
  args?: Record<string, unknown> | undefined;
1395
1396
  dependencies?: string[] | undefined;
1396
1397
  };
1397
- success: boolean;
1398
- result?: unknown;
1399
1398
  error?: string | undefined;
1399
+ result?: unknown;
1400
1400
  }[], {
1401
+ success: boolean;
1401
1402
  timestamp: string;
1402
1403
  step: {
1403
1404
  id: string;
@@ -1406,12 +1407,11 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1406
1407
  args?: Record<string, unknown> | undefined;
1407
1408
  dependencies?: string[] | undefined;
1408
1409
  };
1409
- success: boolean;
1410
- result?: unknown;
1411
1410
  error?: string | undefined;
1411
+ result?: unknown;
1412
1412
  }[], unknown>;
1413
1413
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1414
- status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", unknown>;
1414
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1415
1415
  response: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1416
1416
  error: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1417
1417
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
@@ -1421,7 +1421,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1421
1421
  executor: Partial<PlanExecuteStateType>;
1422
1422
  finisher: Partial<PlanExecuteStateType>;
1423
1423
  replanner: Partial<PlanExecuteStateType>;
1424
- }, unknown, unknown>;
1424
+ }, unknown, unknown, []>;
1425
1425
 
1426
1426
  declare function createPlannerNode(config: PlannerConfig): (state: PlanExecuteStateType) => Promise<Partial<PlanExecuteStateType>>;
1427
1427
 
@@ -1920,7 +1920,7 @@ declare const ReflectionState: _langchain_langgraph.AnnotationRoot<{
1920
1920
  } | undefined;
1921
1921
  }[], unknown>;
1922
1922
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
1923
- status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "generating" | "reflecting" | "revising", unknown>;
1923
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
1924
1924
  qualityCriteria: _langchain_langgraph.BaseChannel<{
1925
1925
  minScore: number;
1926
1926
  requireAll: boolean;
@@ -2215,7 +2215,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2215
2215
  } | undefined;
2216
2216
  }[];
2217
2217
  iteration: number;
2218
- status: "failed" | "completed" | "generating" | "reflecting" | "revising";
2218
+ status: "completed" | "failed" | "generating" | "reflecting" | "revising";
2219
2219
  qualityCriteria: {
2220
2220
  minScore: number;
2221
2221
  requireAll: boolean;
@@ -2249,7 +2249,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2249
2249
  } | undefined;
2250
2250
  }[] | undefined;
2251
2251
  iteration?: number | undefined;
2252
- status?: "failed" | "completed" | "generating" | "reflecting" | "revising" | undefined;
2252
+ status?: "completed" | "failed" | "generating" | "reflecting" | "revising" | undefined;
2253
2253
  qualityCriteria?: {
2254
2254
  minScore: number;
2255
2255
  requireAll: boolean;
@@ -2302,7 +2302,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2302
2302
  } | undefined;
2303
2303
  }[], unknown>;
2304
2304
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
2305
- status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "generating" | "reflecting" | "revising", unknown>;
2305
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
2306
2306
  qualityCriteria: _langchain_langgraph.BaseChannel<{
2307
2307
  minScore: number;
2308
2308
  requireAll: boolean;
@@ -2359,7 +2359,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2359
2359
  } | undefined;
2360
2360
  }[], unknown>;
2361
2361
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
2362
- status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "generating" | "reflecting" | "revising", unknown>;
2362
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
2363
2363
  qualityCriteria: _langchain_langgraph.BaseChannel<{
2364
2364
  minScore: number;
2365
2365
  requireAll: boolean;
@@ -2377,7 +2377,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2377
2377
  reflector: Partial<ReflectionStateType>;
2378
2378
  reviser: Partial<ReflectionStateType>;
2379
2379
  finisher: Partial<ReflectionStateType>;
2380
- }, unknown, unknown>;
2380
+ }, unknown, unknown, []>;
2381
2381
 
2382
2382
  declare const AgentRoleSchema: z.ZodEnum<["supervisor", "worker"]>;
2383
2383
  type AgentRole = z.infer<typeof AgentRoleSchema>;
@@ -2420,29 +2420,29 @@ declare const RoutingDecisionSchema: z.ZodEffects<z.ZodObject<{
2420
2420
  strategy: z.ZodDefault<z.ZodEnum<["llm-based", "rule-based", "round-robin", "skill-based", "load-balanced"]>>;
2421
2421
  timestamp: z.ZodDefault<z.ZodNumber>;
2422
2422
  }, "strip", z.ZodTypeAny, {
2423
- timestamp: number;
2424
2423
  reasoning: string;
2424
+ timestamp: number;
2425
2425
  confidence: number;
2426
2426
  targetAgent: string | null;
2427
2427
  targetAgents: string[] | null;
2428
2428
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2429
2429
  }, {
2430
- timestamp?: number | undefined;
2431
2430
  reasoning?: string | undefined;
2431
+ timestamp?: number | undefined;
2432
2432
  confidence?: number | undefined;
2433
2433
  targetAgent?: string | null | undefined;
2434
2434
  targetAgents?: string[] | null | undefined;
2435
2435
  strategy?: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced" | undefined;
2436
2436
  }>, {
2437
- timestamp: number;
2438
2437
  reasoning: string;
2438
+ timestamp: number;
2439
2439
  confidence: number;
2440
2440
  targetAgent: string | null;
2441
2441
  targetAgents: string[] | null;
2442
2442
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2443
2443
  }, {
2444
- timestamp?: number | undefined;
2445
2444
  reasoning?: string | undefined;
2445
+ timestamp?: number | undefined;
2446
2446
  confidence?: number | undefined;
2447
2447
  targetAgent?: string | null | undefined;
2448
2448
  targetAgents?: string[] | null | undefined;
@@ -2499,21 +2499,21 @@ declare const TaskResultSchema: z.ZodObject<{
2499
2499
  completedAt: z.ZodNumber;
2500
2500
  metadata: z.ZodOptional<z.ZodType<_agentforge_core.JsonObject, z.ZodTypeDef, _agentforge_core.JsonObject>>;
2501
2501
  }, "strip", z.ZodTypeAny, {
2502
- result: string;
2503
2502
  success: boolean;
2503
+ result: string;
2504
2504
  workerId: string;
2505
2505
  assignmentId: string;
2506
2506
  completedAt: number;
2507
- metadata?: _agentforge_core.JsonObject | undefined;
2508
2507
  error?: string | undefined;
2508
+ metadata?: _agentforge_core.JsonObject | undefined;
2509
2509
  }, {
2510
- result: string;
2511
2510
  success: boolean;
2511
+ result: string;
2512
2512
  workerId: string;
2513
2513
  assignmentId: string;
2514
2514
  completedAt: number;
2515
- metadata?: _agentforge_core.JsonObject | undefined;
2516
2515
  error?: string | undefined;
2516
+ metadata?: _agentforge_core.JsonObject | undefined;
2517
2517
  }>;
2518
2518
  type TaskResult = z.infer<typeof TaskResultSchema>;
2519
2519
 
@@ -2656,37 +2656,37 @@ declare const MultiAgentStateConfig: {
2656
2656
  strategy: z.ZodDefault<z.ZodEnum<["llm-based", "rule-based", "round-robin", "skill-based", "load-balanced"]>>;
2657
2657
  timestamp: z.ZodDefault<z.ZodNumber>;
2658
2658
  }, "strip", z.ZodTypeAny, {
2659
- timestamp: number;
2660
2659
  reasoning: string;
2660
+ timestamp: number;
2661
2661
  confidence: number;
2662
2662
  targetAgent: string | null;
2663
2663
  targetAgents: string[] | null;
2664
2664
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2665
2665
  }, {
2666
- timestamp?: number | undefined;
2667
2666
  reasoning?: string | undefined;
2667
+ timestamp?: number | undefined;
2668
2668
  confidence?: number | undefined;
2669
2669
  targetAgent?: string | null | undefined;
2670
2670
  targetAgents?: string[] | null | undefined;
2671
2671
  strategy?: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced" | undefined;
2672
2672
  }>, {
2673
- timestamp: number;
2674
2673
  reasoning: string;
2674
+ timestamp: number;
2675
2675
  confidence: number;
2676
2676
  targetAgent: string | null;
2677
2677
  targetAgents: string[] | null;
2678
2678
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2679
2679
  }, {
2680
- timestamp?: number | undefined;
2681
2680
  reasoning?: string | undefined;
2681
+ timestamp?: number | undefined;
2682
2682
  confidence?: number | undefined;
2683
2683
  targetAgent?: string | null | undefined;
2684
2684
  targetAgents?: string[] | null | undefined;
2685
2685
  strategy?: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced" | undefined;
2686
2686
  }>, "many">;
2687
2687
  reducer: (left: RoutingDecision[], right: RoutingDecision[]) => {
2688
- timestamp: number;
2689
2688
  reasoning: string;
2689
+ timestamp: number;
2690
2690
  confidence: number;
2691
2691
  targetAgent: string | null;
2692
2692
  targetAgents: string[] | null;
@@ -2746,30 +2746,30 @@ declare const MultiAgentStateConfig: {
2746
2746
  completedAt: z.ZodNumber;
2747
2747
  metadata: z.ZodOptional<z.ZodType<_agentforge_core.JsonObject, z.ZodTypeDef, _agentforge_core.JsonObject>>;
2748
2748
  }, "strip", z.ZodTypeAny, {
2749
- result: string;
2750
2749
  success: boolean;
2750
+ result: string;
2751
2751
  workerId: string;
2752
2752
  assignmentId: string;
2753
2753
  completedAt: number;
2754
- metadata?: _agentforge_core.JsonObject | undefined;
2755
2754
  error?: string | undefined;
2755
+ metadata?: _agentforge_core.JsonObject | undefined;
2756
2756
  }, {
2757
- result: string;
2758
2757
  success: boolean;
2758
+ result: string;
2759
2759
  workerId: string;
2760
2760
  assignmentId: string;
2761
2761
  completedAt: number;
2762
- metadata?: _agentforge_core.JsonObject | undefined;
2763
2762
  error?: string | undefined;
2763
+ metadata?: _agentforge_core.JsonObject | undefined;
2764
2764
  }>, "many">;
2765
2765
  reducer: (left: TaskResult[], right: TaskResult[]) => {
2766
- result: string;
2767
2766
  success: boolean;
2767
+ result: string;
2768
2768
  workerId: string;
2769
2769
  assignmentId: string;
2770
2770
  completedAt: number;
2771
- metadata?: _agentforge_core.JsonObject | undefined;
2772
2771
  error?: string | undefined;
2772
+ metadata?: _agentforge_core.JsonObject | undefined;
2773
2773
  }[];
2774
2774
  default: () => never[];
2775
2775
  description: string;
@@ -2886,15 +2886,15 @@ declare const MultiAgentState: _langchain_langgraph.AnnotationRoot<{
2886
2886
  supervisorTask: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
2887
2887
  currentAgent: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
2888
2888
  routingHistory: _langchain_langgraph.BaseChannel<{
2889
- timestamp: number;
2890
2889
  reasoning: string;
2890
+ timestamp: number;
2891
2891
  confidence: number;
2892
2892
  targetAgent: string | null;
2893
2893
  targetAgents: string[] | null;
2894
2894
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2895
2895
  }[], {
2896
- timestamp: number;
2897
2896
  reasoning: string;
2897
+ timestamp: number;
2898
2898
  confidence: number;
2899
2899
  targetAgent: string | null;
2900
2900
  targetAgents: string[] | null;
@@ -2916,21 +2916,21 @@ declare const MultiAgentState: _langchain_langgraph.AnnotationRoot<{
2916
2916
  deadline?: number | undefined;
2917
2917
  }[], unknown>;
2918
2918
  completedTasks: _langchain_langgraph.BaseChannel<{
2919
- result: string;
2920
2919
  success: boolean;
2920
+ result: string;
2921
2921
  workerId: string;
2922
2922
  assignmentId: string;
2923
2923
  completedAt: number;
2924
- metadata?: _agentforge_core.JsonObject | undefined;
2925
2924
  error?: string | undefined;
2925
+ metadata?: _agentforge_core.JsonObject | undefined;
2926
2926
  }[], {
2927
- result: string;
2928
2927
  success: boolean;
2928
+ result: string;
2929
2929
  workerId: string;
2930
2930
  assignmentId: string;
2931
2931
  completedAt: number;
2932
- metadata?: _agentforge_core.JsonObject | undefined;
2933
2932
  error?: string | undefined;
2933
+ metadata?: _agentforge_core.JsonObject | undefined;
2934
2934
  }[], unknown>;
2935
2935
  handoffs: _langchain_langgraph.BaseChannel<{
2936
2936
  timestamp: string;
@@ -2945,7 +2945,7 @@ declare const MultiAgentState: _langchain_langgraph.AnnotationRoot<{
2945
2945
  to: string;
2946
2946
  context?: unknown;
2947
2947
  }[], unknown>;
2948
- status: _langchain_langgraph.BaseChannel<"failed" | "executing" | "completed" | "initializing" | "routing" | "coordinating" | "aggregating", "failed" | "executing" | "completed" | "initializing" | "routing" | "coordinating" | "aggregating", unknown>;
2948
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "executing" | "initializing" | "routing" | "coordinating" | "aggregating", "completed" | "failed" | "executing" | "initializing" | "routing" | "coordinating" | "aggregating", unknown>;
2949
2949
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
2950
2950
  maxIterations: _langchain_langgraph.BaseChannel<number, number, unknown>;
2951
2951
  response: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
package/dist/index.d.ts CHANGED
@@ -81,15 +81,15 @@ declare const ToolResultSchema: z.ZodObject<{
81
81
  isDuplicate: z.ZodOptional<z.ZodBoolean>;
82
82
  }, "strip", z.ZodTypeAny, {
83
83
  toolCallId: string;
84
+ error?: string | undefined;
84
85
  timestamp?: number | undefined;
85
86
  result?: unknown;
86
- error?: string | undefined;
87
87
  isDuplicate?: boolean | undefined;
88
88
  }, {
89
89
  toolCallId: string;
90
+ error?: string | undefined;
90
91
  timestamp?: number | undefined;
91
92
  result?: unknown;
92
- error?: string | undefined;
93
93
  isDuplicate?: boolean | undefined;
94
94
  }>;
95
95
  type ToolResult = z.infer<typeof ToolResultSchema>;
@@ -158,15 +158,15 @@ declare const ReActState: _langchain_langgraph.AnnotationRoot<{
158
158
  }[], unknown>;
159
159
  observations: _langchain_langgraph.BaseChannel<{
160
160
  toolCallId: string;
161
+ error?: string | undefined;
161
162
  timestamp?: number | undefined;
162
163
  result?: unknown;
163
- error?: string | undefined;
164
164
  isDuplicate?: boolean | undefined;
165
165
  }[], {
166
166
  toolCallId: string;
167
+ error?: string | undefined;
167
168
  timestamp?: number | undefined;
168
169
  result?: unknown;
169
- error?: string | undefined;
170
170
  isDuplicate?: boolean | undefined;
171
171
  }[], unknown>;
172
172
  scratchpad: _langchain_langgraph.BaseChannel<{
@@ -644,6 +644,7 @@ declare const CompletedStepSchema: z.ZodObject<{
644
644
  */
645
645
  timestamp: z.ZodString;
646
646
  }, "strip", z.ZodTypeAny, {
647
+ success: boolean;
647
648
  timestamp: string;
648
649
  step: {
649
650
  id: string;
@@ -652,10 +653,10 @@ declare const CompletedStepSchema: z.ZodObject<{
652
653
  args?: Record<string, unknown> | undefined;
653
654
  dependencies?: string[] | undefined;
654
655
  };
655
- success: boolean;
656
- result?: unknown;
657
656
  error?: string | undefined;
657
+ result?: unknown;
658
658
  }, {
659
+ success: boolean;
659
660
  timestamp: string;
660
661
  step: {
661
662
  id: string;
@@ -664,9 +665,8 @@ declare const CompletedStepSchema: z.ZodObject<{
664
665
  args?: Record<string, unknown> | undefined;
665
666
  dependencies?: string[] | undefined;
666
667
  };
667
- success: boolean;
668
- result?: unknown;
669
668
  error?: string | undefined;
669
+ result?: unknown;
670
670
  }>;
671
671
  type CompletedStep = z.infer<typeof CompletedStepSchema>;
672
672
  /**
@@ -875,6 +875,7 @@ declare const PlanExecuteStateConfig: {
875
875
  error: z.ZodOptional<z.ZodString>;
876
876
  timestamp: z.ZodString;
877
877
  }, "strip", z.ZodTypeAny, {
878
+ success: boolean;
878
879
  timestamp: string;
879
880
  step: {
880
881
  id: string;
@@ -883,10 +884,10 @@ declare const PlanExecuteStateConfig: {
883
884
  args?: Record<string, unknown> | undefined;
884
885
  dependencies?: string[] | undefined;
885
886
  };
886
- success: boolean;
887
- result?: unknown;
888
887
  error?: string | undefined;
888
+ result?: unknown;
889
889
  }, {
890
+ success: boolean;
890
891
  timestamp: string;
891
892
  step: {
892
893
  id: string;
@@ -895,11 +896,11 @@ declare const PlanExecuteStateConfig: {
895
896
  args?: Record<string, unknown> | undefined;
896
897
  dependencies?: string[] | undefined;
897
898
  };
898
- success: boolean;
899
- result?: unknown;
900
899
  error?: string | undefined;
900
+ result?: unknown;
901
901
  }>, "many">;
902
902
  reducer: (left: CompletedStep[], right: CompletedStep[]) => {
903
+ success: boolean;
903
904
  timestamp: string;
904
905
  step: {
905
906
  id: string;
@@ -908,9 +909,8 @@ declare const PlanExecuteStateConfig: {
908
909
  args?: Record<string, unknown> | undefined;
909
910
  dependencies?: string[] | undefined;
910
911
  };
911
- success: boolean;
912
- result?: unknown;
913
912
  error?: string | undefined;
913
+ result?: unknown;
914
914
  }[];
915
915
  default: () => never[];
916
916
  description: string;
@@ -993,6 +993,7 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
993
993
  confidence?: number | undefined;
994
994
  } | undefined, unknown>;
995
995
  pastSteps: _langchain_langgraph.BaseChannel<{
996
+ success: boolean;
996
997
  timestamp: string;
997
998
  step: {
998
999
  id: string;
@@ -1001,10 +1002,10 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
1001
1002
  args?: Record<string, unknown> | undefined;
1002
1003
  dependencies?: string[] | undefined;
1003
1004
  };
1004
- success: boolean;
1005
- result?: unknown;
1006
1005
  error?: string | undefined;
1006
+ result?: unknown;
1007
1007
  }[], {
1008
+ success: boolean;
1008
1009
  timestamp: string;
1009
1010
  step: {
1010
1011
  id: string;
@@ -1013,12 +1014,11 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
1013
1014
  args?: Record<string, unknown> | undefined;
1014
1015
  dependencies?: string[] | undefined;
1015
1016
  };
1016
- success: boolean;
1017
- result?: unknown;
1018
1017
  error?: string | undefined;
1018
+ result?: unknown;
1019
1019
  }[], unknown>;
1020
1020
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1021
- status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", unknown>;
1021
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1022
1022
  response: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1023
1023
  error: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1024
1024
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
@@ -1253,6 +1253,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1253
1253
  confidence?: number | undefined;
1254
1254
  } | undefined;
1255
1255
  pastSteps: {
1256
+ success: boolean;
1256
1257
  timestamp: string;
1257
1258
  step: {
1258
1259
  id: string;
@@ -1261,12 +1262,11 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1261
1262
  args?: Record<string, unknown> | undefined;
1262
1263
  dependencies?: string[] | undefined;
1263
1264
  };
1264
- success: boolean;
1265
- result?: unknown;
1266
1265
  error?: string | undefined;
1266
+ result?: unknown;
1267
1267
  }[];
1268
1268
  currentStepIndex: number | undefined;
1269
- status: "failed" | "planning" | "executing" | "replanning" | "completed";
1269
+ status: "completed" | "failed" | "planning" | "executing" | "replanning";
1270
1270
  response: string | undefined;
1271
1271
  error: string | undefined;
1272
1272
  iteration: number;
@@ -1286,6 +1286,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1286
1286
  confidence?: number | undefined;
1287
1287
  } | undefined;
1288
1288
  pastSteps?: {
1289
+ success: boolean;
1289
1290
  timestamp: string;
1290
1291
  step: {
1291
1292
  id: string;
@@ -1294,12 +1295,11 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1294
1295
  args?: Record<string, unknown> | undefined;
1295
1296
  dependencies?: string[] | undefined;
1296
1297
  };
1297
- success: boolean;
1298
- result?: unknown;
1299
1298
  error?: string | undefined;
1299
+ result?: unknown;
1300
1300
  }[] | undefined;
1301
1301
  currentStepIndex?: number | undefined;
1302
- status?: "failed" | "planning" | "executing" | "replanning" | "completed" | undefined;
1302
+ status?: "completed" | "failed" | "planning" | "executing" | "replanning" | undefined;
1303
1303
  response?: string | undefined;
1304
1304
  error?: string | undefined;
1305
1305
  iteration?: number | undefined;
@@ -1330,6 +1330,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1330
1330
  confidence?: number | undefined;
1331
1331
  } | undefined, unknown>;
1332
1332
  pastSteps: _langchain_langgraph.BaseChannel<{
1333
+ success: boolean;
1333
1334
  timestamp: string;
1334
1335
  step: {
1335
1336
  id: string;
@@ -1338,10 +1339,10 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1338
1339
  args?: Record<string, unknown> | undefined;
1339
1340
  dependencies?: string[] | undefined;
1340
1341
  };
1341
- success: boolean;
1342
- result?: unknown;
1343
1342
  error?: string | undefined;
1343
+ result?: unknown;
1344
1344
  }[], {
1345
+ success: boolean;
1345
1346
  timestamp: string;
1346
1347
  step: {
1347
1348
  id: string;
@@ -1350,12 +1351,11 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1350
1351
  args?: Record<string, unknown> | undefined;
1351
1352
  dependencies?: string[] | undefined;
1352
1353
  };
1353
- success: boolean;
1354
- result?: unknown;
1355
1354
  error?: string | undefined;
1355
+ result?: unknown;
1356
1356
  }[], unknown>;
1357
1357
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1358
- status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", unknown>;
1358
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1359
1359
  response: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1360
1360
  error: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1361
1361
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
@@ -1386,6 +1386,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1386
1386
  confidence?: number | undefined;
1387
1387
  } | undefined, unknown>;
1388
1388
  pastSteps: _langchain_langgraph.BaseChannel<{
1389
+ success: boolean;
1389
1390
  timestamp: string;
1390
1391
  step: {
1391
1392
  id: string;
@@ -1394,10 +1395,10 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1394
1395
  args?: Record<string, unknown> | undefined;
1395
1396
  dependencies?: string[] | undefined;
1396
1397
  };
1397
- success: boolean;
1398
- result?: unknown;
1399
1398
  error?: string | undefined;
1399
+ result?: unknown;
1400
1400
  }[], {
1401
+ success: boolean;
1401
1402
  timestamp: string;
1402
1403
  step: {
1403
1404
  id: string;
@@ -1406,12 +1407,11 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1406
1407
  args?: Record<string, unknown> | undefined;
1407
1408
  dependencies?: string[] | undefined;
1408
1409
  };
1409
- success: boolean;
1410
- result?: unknown;
1411
1410
  error?: string | undefined;
1411
+ result?: unknown;
1412
1412
  }[], unknown>;
1413
1413
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1414
- status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", unknown>;
1414
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1415
1415
  response: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1416
1416
  error: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
1417
1417
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
@@ -1421,7 +1421,7 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1421
1421
  executor: Partial<PlanExecuteStateType>;
1422
1422
  finisher: Partial<PlanExecuteStateType>;
1423
1423
  replanner: Partial<PlanExecuteStateType>;
1424
- }, unknown, unknown>;
1424
+ }, unknown, unknown, []>;
1425
1425
 
1426
1426
  declare function createPlannerNode(config: PlannerConfig): (state: PlanExecuteStateType) => Promise<Partial<PlanExecuteStateType>>;
1427
1427
 
@@ -1920,7 +1920,7 @@ declare const ReflectionState: _langchain_langgraph.AnnotationRoot<{
1920
1920
  } | undefined;
1921
1921
  }[], unknown>;
1922
1922
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
1923
- status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "generating" | "reflecting" | "revising", unknown>;
1923
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
1924
1924
  qualityCriteria: _langchain_langgraph.BaseChannel<{
1925
1925
  minScore: number;
1926
1926
  requireAll: boolean;
@@ -2215,7 +2215,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2215
2215
  } | undefined;
2216
2216
  }[];
2217
2217
  iteration: number;
2218
- status: "failed" | "completed" | "generating" | "reflecting" | "revising";
2218
+ status: "completed" | "failed" | "generating" | "reflecting" | "revising";
2219
2219
  qualityCriteria: {
2220
2220
  minScore: number;
2221
2221
  requireAll: boolean;
@@ -2249,7 +2249,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2249
2249
  } | undefined;
2250
2250
  }[] | undefined;
2251
2251
  iteration?: number | undefined;
2252
- status?: "failed" | "completed" | "generating" | "reflecting" | "revising" | undefined;
2252
+ status?: "completed" | "failed" | "generating" | "reflecting" | "revising" | undefined;
2253
2253
  qualityCriteria?: {
2254
2254
  minScore: number;
2255
2255
  requireAll: boolean;
@@ -2302,7 +2302,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2302
2302
  } | undefined;
2303
2303
  }[], unknown>;
2304
2304
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
2305
- status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "generating" | "reflecting" | "revising", unknown>;
2305
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
2306
2306
  qualityCriteria: _langchain_langgraph.BaseChannel<{
2307
2307
  minScore: number;
2308
2308
  requireAll: boolean;
@@ -2359,7 +2359,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2359
2359
  } | undefined;
2360
2360
  }[], unknown>;
2361
2361
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
2362
- status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "generating" | "reflecting" | "revising", unknown>;
2362
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
2363
2363
  qualityCriteria: _langchain_langgraph.BaseChannel<{
2364
2364
  minScore: number;
2365
2365
  requireAll: boolean;
@@ -2377,7 +2377,7 @@ declare function createReflectionAgent(config: ReflectionAgentConfig): _langchai
2377
2377
  reflector: Partial<ReflectionStateType>;
2378
2378
  reviser: Partial<ReflectionStateType>;
2379
2379
  finisher: Partial<ReflectionStateType>;
2380
- }, unknown, unknown>;
2380
+ }, unknown, unknown, []>;
2381
2381
 
2382
2382
  declare const AgentRoleSchema: z.ZodEnum<["supervisor", "worker"]>;
2383
2383
  type AgentRole = z.infer<typeof AgentRoleSchema>;
@@ -2420,29 +2420,29 @@ declare const RoutingDecisionSchema: z.ZodEffects<z.ZodObject<{
2420
2420
  strategy: z.ZodDefault<z.ZodEnum<["llm-based", "rule-based", "round-robin", "skill-based", "load-balanced"]>>;
2421
2421
  timestamp: z.ZodDefault<z.ZodNumber>;
2422
2422
  }, "strip", z.ZodTypeAny, {
2423
- timestamp: number;
2424
2423
  reasoning: string;
2424
+ timestamp: number;
2425
2425
  confidence: number;
2426
2426
  targetAgent: string | null;
2427
2427
  targetAgents: string[] | null;
2428
2428
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2429
2429
  }, {
2430
- timestamp?: number | undefined;
2431
2430
  reasoning?: string | undefined;
2431
+ timestamp?: number | undefined;
2432
2432
  confidence?: number | undefined;
2433
2433
  targetAgent?: string | null | undefined;
2434
2434
  targetAgents?: string[] | null | undefined;
2435
2435
  strategy?: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced" | undefined;
2436
2436
  }>, {
2437
- timestamp: number;
2438
2437
  reasoning: string;
2438
+ timestamp: number;
2439
2439
  confidence: number;
2440
2440
  targetAgent: string | null;
2441
2441
  targetAgents: string[] | null;
2442
2442
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2443
2443
  }, {
2444
- timestamp?: number | undefined;
2445
2444
  reasoning?: string | undefined;
2445
+ timestamp?: number | undefined;
2446
2446
  confidence?: number | undefined;
2447
2447
  targetAgent?: string | null | undefined;
2448
2448
  targetAgents?: string[] | null | undefined;
@@ -2499,21 +2499,21 @@ declare const TaskResultSchema: z.ZodObject<{
2499
2499
  completedAt: z.ZodNumber;
2500
2500
  metadata: z.ZodOptional<z.ZodType<_agentforge_core.JsonObject, z.ZodTypeDef, _agentforge_core.JsonObject>>;
2501
2501
  }, "strip", z.ZodTypeAny, {
2502
- result: string;
2503
2502
  success: boolean;
2503
+ result: string;
2504
2504
  workerId: string;
2505
2505
  assignmentId: string;
2506
2506
  completedAt: number;
2507
- metadata?: _agentforge_core.JsonObject | undefined;
2508
2507
  error?: string | undefined;
2508
+ metadata?: _agentforge_core.JsonObject | undefined;
2509
2509
  }, {
2510
- result: string;
2511
2510
  success: boolean;
2511
+ result: string;
2512
2512
  workerId: string;
2513
2513
  assignmentId: string;
2514
2514
  completedAt: number;
2515
- metadata?: _agentforge_core.JsonObject | undefined;
2516
2515
  error?: string | undefined;
2516
+ metadata?: _agentforge_core.JsonObject | undefined;
2517
2517
  }>;
2518
2518
  type TaskResult = z.infer<typeof TaskResultSchema>;
2519
2519
 
@@ -2656,37 +2656,37 @@ declare const MultiAgentStateConfig: {
2656
2656
  strategy: z.ZodDefault<z.ZodEnum<["llm-based", "rule-based", "round-robin", "skill-based", "load-balanced"]>>;
2657
2657
  timestamp: z.ZodDefault<z.ZodNumber>;
2658
2658
  }, "strip", z.ZodTypeAny, {
2659
- timestamp: number;
2660
2659
  reasoning: string;
2660
+ timestamp: number;
2661
2661
  confidence: number;
2662
2662
  targetAgent: string | null;
2663
2663
  targetAgents: string[] | null;
2664
2664
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2665
2665
  }, {
2666
- timestamp?: number | undefined;
2667
2666
  reasoning?: string | undefined;
2667
+ timestamp?: number | undefined;
2668
2668
  confidence?: number | undefined;
2669
2669
  targetAgent?: string | null | undefined;
2670
2670
  targetAgents?: string[] | null | undefined;
2671
2671
  strategy?: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced" | undefined;
2672
2672
  }>, {
2673
- timestamp: number;
2674
2673
  reasoning: string;
2674
+ timestamp: number;
2675
2675
  confidence: number;
2676
2676
  targetAgent: string | null;
2677
2677
  targetAgents: string[] | null;
2678
2678
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2679
2679
  }, {
2680
- timestamp?: number | undefined;
2681
2680
  reasoning?: string | undefined;
2681
+ timestamp?: number | undefined;
2682
2682
  confidence?: number | undefined;
2683
2683
  targetAgent?: string | null | undefined;
2684
2684
  targetAgents?: string[] | null | undefined;
2685
2685
  strategy?: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced" | undefined;
2686
2686
  }>, "many">;
2687
2687
  reducer: (left: RoutingDecision[], right: RoutingDecision[]) => {
2688
- timestamp: number;
2689
2688
  reasoning: string;
2689
+ timestamp: number;
2690
2690
  confidence: number;
2691
2691
  targetAgent: string | null;
2692
2692
  targetAgents: string[] | null;
@@ -2746,30 +2746,30 @@ declare const MultiAgentStateConfig: {
2746
2746
  completedAt: z.ZodNumber;
2747
2747
  metadata: z.ZodOptional<z.ZodType<_agentforge_core.JsonObject, z.ZodTypeDef, _agentforge_core.JsonObject>>;
2748
2748
  }, "strip", z.ZodTypeAny, {
2749
- result: string;
2750
2749
  success: boolean;
2750
+ result: string;
2751
2751
  workerId: string;
2752
2752
  assignmentId: string;
2753
2753
  completedAt: number;
2754
- metadata?: _agentforge_core.JsonObject | undefined;
2755
2754
  error?: string | undefined;
2755
+ metadata?: _agentforge_core.JsonObject | undefined;
2756
2756
  }, {
2757
- result: string;
2758
2757
  success: boolean;
2758
+ result: string;
2759
2759
  workerId: string;
2760
2760
  assignmentId: string;
2761
2761
  completedAt: number;
2762
- metadata?: _agentforge_core.JsonObject | undefined;
2763
2762
  error?: string | undefined;
2763
+ metadata?: _agentforge_core.JsonObject | undefined;
2764
2764
  }>, "many">;
2765
2765
  reducer: (left: TaskResult[], right: TaskResult[]) => {
2766
- result: string;
2767
2766
  success: boolean;
2767
+ result: string;
2768
2768
  workerId: string;
2769
2769
  assignmentId: string;
2770
2770
  completedAt: number;
2771
- metadata?: _agentforge_core.JsonObject | undefined;
2772
2771
  error?: string | undefined;
2772
+ metadata?: _agentforge_core.JsonObject | undefined;
2773
2773
  }[];
2774
2774
  default: () => never[];
2775
2775
  description: string;
@@ -2886,15 +2886,15 @@ declare const MultiAgentState: _langchain_langgraph.AnnotationRoot<{
2886
2886
  supervisorTask: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
2887
2887
  currentAgent: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
2888
2888
  routingHistory: _langchain_langgraph.BaseChannel<{
2889
- timestamp: number;
2890
2889
  reasoning: string;
2890
+ timestamp: number;
2891
2891
  confidence: number;
2892
2892
  targetAgent: string | null;
2893
2893
  targetAgents: string[] | null;
2894
2894
  strategy: "llm-based" | "rule-based" | "round-robin" | "skill-based" | "load-balanced";
2895
2895
  }[], {
2896
- timestamp: number;
2897
2896
  reasoning: string;
2897
+ timestamp: number;
2898
2898
  confidence: number;
2899
2899
  targetAgent: string | null;
2900
2900
  targetAgents: string[] | null;
@@ -2916,21 +2916,21 @@ declare const MultiAgentState: _langchain_langgraph.AnnotationRoot<{
2916
2916
  deadline?: number | undefined;
2917
2917
  }[], unknown>;
2918
2918
  completedTasks: _langchain_langgraph.BaseChannel<{
2919
- result: string;
2920
2919
  success: boolean;
2920
+ result: string;
2921
2921
  workerId: string;
2922
2922
  assignmentId: string;
2923
2923
  completedAt: number;
2924
- metadata?: _agentforge_core.JsonObject | undefined;
2925
2924
  error?: string | undefined;
2925
+ metadata?: _agentforge_core.JsonObject | undefined;
2926
2926
  }[], {
2927
- result: string;
2928
2927
  success: boolean;
2928
+ result: string;
2929
2929
  workerId: string;
2930
2930
  assignmentId: string;
2931
2931
  completedAt: number;
2932
- metadata?: _agentforge_core.JsonObject | undefined;
2933
2932
  error?: string | undefined;
2933
+ metadata?: _agentforge_core.JsonObject | undefined;
2934
2934
  }[], unknown>;
2935
2935
  handoffs: _langchain_langgraph.BaseChannel<{
2936
2936
  timestamp: string;
@@ -2945,7 +2945,7 @@ declare const MultiAgentState: _langchain_langgraph.AnnotationRoot<{
2945
2945
  to: string;
2946
2946
  context?: unknown;
2947
2947
  }[], unknown>;
2948
- status: _langchain_langgraph.BaseChannel<"failed" | "executing" | "completed" | "initializing" | "routing" | "coordinating" | "aggregating", "failed" | "executing" | "completed" | "initializing" | "routing" | "coordinating" | "aggregating", unknown>;
2948
+ status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "executing" | "initializing" | "routing" | "coordinating" | "aggregating", "completed" | "failed" | "executing" | "initializing" | "routing" | "coordinating" | "aggregating", unknown>;
2949
2949
  iteration: _langchain_langgraph.BaseChannel<number, number, unknown>;
2950
2950
  maxIterations: _langchain_langgraph.BaseChannel<number, number, unknown>;
2951
2951
  response: _langchain_langgraph.BaseChannel<string | undefined, string | undefined, unknown>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agentforge/patterns",
3
- "version": "0.16.79",
3
+ "version": "0.16.81",
4
4
  "description": "Production-ready agent workflow patterns for TypeScript including ReAct and Planner-Executor, built on LangGraph.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -41,13 +41,13 @@
41
41
  "url": "https://github.com/TVScoundrel/agentforge/issues"
42
42
  },
43
43
  "dependencies": {
44
- "@agentforge/core": "0.16.79",
44
+ "@agentforge/core": "0.16.81",
45
45
  "@langchain/core": "^1.1.17",
46
46
  "@langchain/langgraph": "^1.1.2",
47
47
  "zod": "^3.23.8"
48
48
  },
49
49
  "devDependencies": {
50
- "@agentforge/testing": "0.16.79",
50
+ "@agentforge/testing": "0.16.81",
51
51
  "@eslint/js": "^9.17.0",
52
52
  "@types/node": "^22.10.2",
53
53
  "eslint": "^9.17.0",