@agentforge/patterns 0.16.86 → 0.16.87

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;
85
84
  timestamp?: number | undefined;
86
85
  result?: unknown;
86
+ error?: string | undefined;
87
87
  isDuplicate?: boolean | undefined;
88
88
  }, {
89
89
  toolCallId: string;
90
- error?: string | undefined;
91
90
  timestamp?: number | undefined;
92
91
  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;
162
161
  timestamp?: number | undefined;
163
162
  result?: unknown;
163
+ error?: string | undefined;
164
164
  isDuplicate?: boolean | undefined;
165
165
  }[], {
166
166
  toolCallId: string;
167
- error?: string | undefined;
168
167
  timestamp?: number | undefined;
169
168
  result?: unknown;
169
+ error?: string | undefined;
170
170
  isDuplicate?: boolean | undefined;
171
171
  }[], unknown>;
172
172
  scratchpad: _langchain_langgraph.BaseChannel<{
@@ -644,7 +644,6 @@ declare const CompletedStepSchema: z.ZodObject<{
644
644
  */
645
645
  timestamp: z.ZodString;
646
646
  }, "strip", z.ZodTypeAny, {
647
- success: boolean;
648
647
  timestamp: string;
649
648
  step: {
650
649
  id: string;
@@ -653,10 +652,10 @@ declare const CompletedStepSchema: z.ZodObject<{
653
652
  args?: Record<string, unknown> | undefined;
654
653
  dependencies?: string[] | undefined;
655
654
  };
656
- error?: string | undefined;
655
+ success: boolean;
657
656
  result?: unknown;
657
+ error?: string | undefined;
658
658
  }, {
659
- success: boolean;
660
659
  timestamp: string;
661
660
  step: {
662
661
  id: string;
@@ -665,8 +664,9 @@ declare const CompletedStepSchema: z.ZodObject<{
665
664
  args?: Record<string, unknown> | undefined;
666
665
  dependencies?: string[] | undefined;
667
666
  };
668
- error?: string | undefined;
667
+ success: boolean;
669
668
  result?: unknown;
669
+ error?: string | undefined;
670
670
  }>;
671
671
  type CompletedStep = z.infer<typeof CompletedStepSchema>;
672
672
  /**
@@ -875,7 +875,6 @@ declare const PlanExecuteStateConfig: {
875
875
  error: z.ZodOptional<z.ZodString>;
876
876
  timestamp: z.ZodString;
877
877
  }, "strip", z.ZodTypeAny, {
878
- success: boolean;
879
878
  timestamp: string;
880
879
  step: {
881
880
  id: string;
@@ -884,10 +883,10 @@ declare const PlanExecuteStateConfig: {
884
883
  args?: Record<string, unknown> | undefined;
885
884
  dependencies?: string[] | undefined;
886
885
  };
887
- error?: string | undefined;
886
+ success: boolean;
888
887
  result?: unknown;
888
+ error?: string | undefined;
889
889
  }, {
890
- success: boolean;
891
890
  timestamp: string;
892
891
  step: {
893
892
  id: string;
@@ -896,11 +895,11 @@ declare const PlanExecuteStateConfig: {
896
895
  args?: Record<string, unknown> | undefined;
897
896
  dependencies?: string[] | undefined;
898
897
  };
899
- error?: string | undefined;
898
+ success: boolean;
900
899
  result?: unknown;
900
+ error?: string | undefined;
901
901
  }>, "many">;
902
902
  reducer: (left: CompletedStep[], right: CompletedStep[]) => {
903
- success: boolean;
904
903
  timestamp: string;
905
904
  step: {
906
905
  id: string;
@@ -909,8 +908,9 @@ declare const PlanExecuteStateConfig: {
909
908
  args?: Record<string, unknown> | undefined;
910
909
  dependencies?: string[] | undefined;
911
910
  };
912
- error?: string | undefined;
911
+ success: boolean;
913
912
  result?: unknown;
913
+ error?: string | undefined;
914
914
  }[];
915
915
  default: () => never[];
916
916
  description: string;
@@ -993,7 +993,6 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
993
993
  confidence?: number | undefined;
994
994
  } | undefined, unknown>;
995
995
  pastSteps: _langchain_langgraph.BaseChannel<{
996
- success: boolean;
997
996
  timestamp: string;
998
997
  step: {
999
998
  id: string;
@@ -1002,10 +1001,10 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
1002
1001
  args?: Record<string, unknown> | undefined;
1003
1002
  dependencies?: string[] | undefined;
1004
1003
  };
1005
- error?: string | undefined;
1004
+ success: boolean;
1006
1005
  result?: unknown;
1006
+ error?: string | undefined;
1007
1007
  }[], {
1008
- success: boolean;
1009
1008
  timestamp: string;
1010
1009
  step: {
1011
1010
  id: string;
@@ -1014,11 +1013,12 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
1014
1013
  args?: Record<string, unknown> | undefined;
1015
1014
  dependencies?: string[] | undefined;
1016
1015
  };
1017
- error?: string | undefined;
1016
+ success: boolean;
1018
1017
  result?: unknown;
1018
+ error?: string | undefined;
1019
1019
  }[], unknown>;
1020
1020
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1021
- status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1021
+ status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", 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,7 +1253,6 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1253
1253
  confidence?: number | undefined;
1254
1254
  } | undefined;
1255
1255
  pastSteps: {
1256
- success: boolean;
1257
1256
  timestamp: string;
1258
1257
  step: {
1259
1258
  id: string;
@@ -1262,11 +1261,12 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1262
1261
  args?: Record<string, unknown> | undefined;
1263
1262
  dependencies?: string[] | undefined;
1264
1263
  };
1265
- error?: string | undefined;
1264
+ success: boolean;
1266
1265
  result?: unknown;
1266
+ error?: string | undefined;
1267
1267
  }[];
1268
1268
  currentStepIndex: number | undefined;
1269
- status: "completed" | "failed" | "planning" | "executing" | "replanning";
1269
+ status: "failed" | "planning" | "executing" | "replanning" | "completed";
1270
1270
  response: string | undefined;
1271
1271
  error: string | undefined;
1272
1272
  iteration: number;
@@ -1286,7 +1286,6 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1286
1286
  confidence?: number | undefined;
1287
1287
  } | undefined;
1288
1288
  pastSteps?: {
1289
- success: boolean;
1290
1289
  timestamp: string;
1291
1290
  step: {
1292
1291
  id: string;
@@ -1295,11 +1294,12 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1295
1294
  args?: Record<string, unknown> | undefined;
1296
1295
  dependencies?: string[] | undefined;
1297
1296
  };
1298
- error?: string | undefined;
1297
+ success: boolean;
1299
1298
  result?: unknown;
1299
+ error?: string | undefined;
1300
1300
  }[] | undefined;
1301
1301
  currentStepIndex?: number | undefined;
1302
- status?: "completed" | "failed" | "planning" | "executing" | "replanning" | undefined;
1302
+ status?: "failed" | "planning" | "executing" | "replanning" | "completed" | undefined;
1303
1303
  response?: string | undefined;
1304
1304
  error?: string | undefined;
1305
1305
  iteration?: number | undefined;
@@ -1330,7 +1330,6 @@ 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;
1334
1333
  timestamp: string;
1335
1334
  step: {
1336
1335
  id: string;
@@ -1339,10 +1338,10 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1339
1338
  args?: Record<string, unknown> | undefined;
1340
1339
  dependencies?: string[] | undefined;
1341
1340
  };
1342
- error?: string | undefined;
1341
+ success: boolean;
1343
1342
  result?: unknown;
1343
+ error?: string | undefined;
1344
1344
  }[], {
1345
- success: boolean;
1346
1345
  timestamp: string;
1347
1346
  step: {
1348
1347
  id: string;
@@ -1351,11 +1350,12 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1351
1350
  args?: Record<string, unknown> | undefined;
1352
1351
  dependencies?: string[] | undefined;
1353
1352
  };
1354
- error?: string | undefined;
1353
+ success: boolean;
1355
1354
  result?: unknown;
1355
+ error?: string | undefined;
1356
1356
  }[], unknown>;
1357
1357
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1358
- status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1358
+ status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", 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,7 +1386,6 @@ 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;
1390
1389
  timestamp: string;
1391
1390
  step: {
1392
1391
  id: string;
@@ -1395,10 +1394,10 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1395
1394
  args?: Record<string, unknown> | undefined;
1396
1395
  dependencies?: string[] | undefined;
1397
1396
  };
1398
- error?: string | undefined;
1397
+ success: boolean;
1399
1398
  result?: unknown;
1399
+ error?: string | undefined;
1400
1400
  }[], {
1401
- success: boolean;
1402
1401
  timestamp: string;
1403
1402
  step: {
1404
1403
  id: string;
@@ -1407,11 +1406,12 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1407
1406
  args?: Record<string, unknown> | undefined;
1408
1407
  dependencies?: string[] | undefined;
1409
1408
  };
1410
- error?: string | undefined;
1409
+ success: boolean;
1411
1410
  result?: unknown;
1411
+ error?: string | undefined;
1412
1412
  }[], unknown>;
1413
1413
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1414
- status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1414
+ status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", 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<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
1923
+ status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "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: "completed" | "failed" | "generating" | "reflecting" | "revising";
2218
+ status: "failed" | "completed" | "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?: "completed" | "failed" | "generating" | "reflecting" | "revising" | undefined;
2252
+ status?: "failed" | "completed" | "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<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
2305
+ status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "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<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
2362
+ status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "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
- reasoning: string;
2424
2423
  timestamp: number;
2424
+ reasoning: string;
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
- reasoning?: string | undefined;
2431
2430
  timestamp?: number | undefined;
2431
+ reasoning?: string | 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
- reasoning: string;
2438
2437
  timestamp: number;
2438
+ reasoning: string;
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
- reasoning?: string | undefined;
2445
2444
  timestamp?: number | undefined;
2445
+ reasoning?: string | 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
- success: boolean;
2503
2502
  result: string;
2503
+ success: boolean;
2504
2504
  workerId: string;
2505
2505
  assignmentId: string;
2506
2506
  completedAt: number;
2507
- error?: string | undefined;
2508
2507
  metadata?: _agentforge_core.JsonObject | undefined;
2508
+ error?: string | undefined;
2509
2509
  }, {
2510
- success: boolean;
2511
2510
  result: string;
2511
+ success: boolean;
2512
2512
  workerId: string;
2513
2513
  assignmentId: string;
2514
2514
  completedAt: number;
2515
- error?: string | undefined;
2516
2515
  metadata?: _agentforge_core.JsonObject | undefined;
2516
+ error?: string | 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
- reasoning: string;
2660
2659
  timestamp: number;
2660
+ reasoning: string;
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
- reasoning?: string | undefined;
2667
2666
  timestamp?: number | undefined;
2667
+ reasoning?: string | 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
- reasoning: string;
2674
2673
  timestamp: number;
2674
+ reasoning: string;
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
- reasoning?: string | undefined;
2681
2680
  timestamp?: number | undefined;
2681
+ reasoning?: string | 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
- reasoning: string;
2689
2688
  timestamp: number;
2689
+ reasoning: string;
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
- success: boolean;
2750
2749
  result: string;
2750
+ success: boolean;
2751
2751
  workerId: string;
2752
2752
  assignmentId: string;
2753
2753
  completedAt: number;
2754
- error?: string | undefined;
2755
2754
  metadata?: _agentforge_core.JsonObject | undefined;
2755
+ error?: string | undefined;
2756
2756
  }, {
2757
- success: boolean;
2758
2757
  result: string;
2758
+ success: boolean;
2759
2759
  workerId: string;
2760
2760
  assignmentId: string;
2761
2761
  completedAt: number;
2762
- error?: string | undefined;
2763
2762
  metadata?: _agentforge_core.JsonObject | undefined;
2763
+ error?: string | undefined;
2764
2764
  }>, "many">;
2765
2765
  reducer: (left: TaskResult[], right: TaskResult[]) => {
2766
- success: boolean;
2767
2766
  result: string;
2767
+ success: boolean;
2768
2768
  workerId: string;
2769
2769
  assignmentId: string;
2770
2770
  completedAt: number;
2771
- error?: string | undefined;
2772
2771
  metadata?: _agentforge_core.JsonObject | undefined;
2772
+ error?: string | 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
- reasoning: string;
2890
2889
  timestamp: number;
2890
+ reasoning: string;
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
- reasoning: string;
2897
2896
  timestamp: number;
2897
+ reasoning: string;
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
- success: boolean;
2920
2919
  result: string;
2920
+ success: boolean;
2921
2921
  workerId: string;
2922
2922
  assignmentId: string;
2923
2923
  completedAt: number;
2924
- error?: string | undefined;
2925
2924
  metadata?: _agentforge_core.JsonObject | undefined;
2925
+ error?: string | undefined;
2926
2926
  }[], {
2927
- success: boolean;
2928
2927
  result: string;
2928
+ success: boolean;
2929
2929
  workerId: string;
2930
2930
  assignmentId: string;
2931
2931
  completedAt: number;
2932
- error?: string | undefined;
2933
2932
  metadata?: _agentforge_core.JsonObject | undefined;
2933
+ error?: string | 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<"completed" | "failed" | "executing" | "initializing" | "routing" | "coordinating" | "aggregating", "completed" | "failed" | "executing" | "initializing" | "routing" | "coordinating" | "aggregating", unknown>;
2948
+ status: _langchain_langgraph.BaseChannel<"failed" | "executing" | "completed" | "initializing" | "routing" | "coordinating" | "aggregating", "failed" | "executing" | "completed" | "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;
85
84
  timestamp?: number | undefined;
86
85
  result?: unknown;
86
+ error?: string | undefined;
87
87
  isDuplicate?: boolean | undefined;
88
88
  }, {
89
89
  toolCallId: string;
90
- error?: string | undefined;
91
90
  timestamp?: number | undefined;
92
91
  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;
162
161
  timestamp?: number | undefined;
163
162
  result?: unknown;
163
+ error?: string | undefined;
164
164
  isDuplicate?: boolean | undefined;
165
165
  }[], {
166
166
  toolCallId: string;
167
- error?: string | undefined;
168
167
  timestamp?: number | undefined;
169
168
  result?: unknown;
169
+ error?: string | undefined;
170
170
  isDuplicate?: boolean | undefined;
171
171
  }[], unknown>;
172
172
  scratchpad: _langchain_langgraph.BaseChannel<{
@@ -644,7 +644,6 @@ declare const CompletedStepSchema: z.ZodObject<{
644
644
  */
645
645
  timestamp: z.ZodString;
646
646
  }, "strip", z.ZodTypeAny, {
647
- success: boolean;
648
647
  timestamp: string;
649
648
  step: {
650
649
  id: string;
@@ -653,10 +652,10 @@ declare const CompletedStepSchema: z.ZodObject<{
653
652
  args?: Record<string, unknown> | undefined;
654
653
  dependencies?: string[] | undefined;
655
654
  };
656
- error?: string | undefined;
655
+ success: boolean;
657
656
  result?: unknown;
657
+ error?: string | undefined;
658
658
  }, {
659
- success: boolean;
660
659
  timestamp: string;
661
660
  step: {
662
661
  id: string;
@@ -665,8 +664,9 @@ declare const CompletedStepSchema: z.ZodObject<{
665
664
  args?: Record<string, unknown> | undefined;
666
665
  dependencies?: string[] | undefined;
667
666
  };
668
- error?: string | undefined;
667
+ success: boolean;
669
668
  result?: unknown;
669
+ error?: string | undefined;
670
670
  }>;
671
671
  type CompletedStep = z.infer<typeof CompletedStepSchema>;
672
672
  /**
@@ -875,7 +875,6 @@ declare const PlanExecuteStateConfig: {
875
875
  error: z.ZodOptional<z.ZodString>;
876
876
  timestamp: z.ZodString;
877
877
  }, "strip", z.ZodTypeAny, {
878
- success: boolean;
879
878
  timestamp: string;
880
879
  step: {
881
880
  id: string;
@@ -884,10 +883,10 @@ declare const PlanExecuteStateConfig: {
884
883
  args?: Record<string, unknown> | undefined;
885
884
  dependencies?: string[] | undefined;
886
885
  };
887
- error?: string | undefined;
886
+ success: boolean;
888
887
  result?: unknown;
888
+ error?: string | undefined;
889
889
  }, {
890
- success: boolean;
891
890
  timestamp: string;
892
891
  step: {
893
892
  id: string;
@@ -896,11 +895,11 @@ declare const PlanExecuteStateConfig: {
896
895
  args?: Record<string, unknown> | undefined;
897
896
  dependencies?: string[] | undefined;
898
897
  };
899
- error?: string | undefined;
898
+ success: boolean;
900
899
  result?: unknown;
900
+ error?: string | undefined;
901
901
  }>, "many">;
902
902
  reducer: (left: CompletedStep[], right: CompletedStep[]) => {
903
- success: boolean;
904
903
  timestamp: string;
905
904
  step: {
906
905
  id: string;
@@ -909,8 +908,9 @@ declare const PlanExecuteStateConfig: {
909
908
  args?: Record<string, unknown> | undefined;
910
909
  dependencies?: string[] | undefined;
911
910
  };
912
- error?: string | undefined;
911
+ success: boolean;
913
912
  result?: unknown;
913
+ error?: string | undefined;
914
914
  }[];
915
915
  default: () => never[];
916
916
  description: string;
@@ -993,7 +993,6 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
993
993
  confidence?: number | undefined;
994
994
  } | undefined, unknown>;
995
995
  pastSteps: _langchain_langgraph.BaseChannel<{
996
- success: boolean;
997
996
  timestamp: string;
998
997
  step: {
999
998
  id: string;
@@ -1002,10 +1001,10 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
1002
1001
  args?: Record<string, unknown> | undefined;
1003
1002
  dependencies?: string[] | undefined;
1004
1003
  };
1005
- error?: string | undefined;
1004
+ success: boolean;
1006
1005
  result?: unknown;
1006
+ error?: string | undefined;
1007
1007
  }[], {
1008
- success: boolean;
1009
1008
  timestamp: string;
1010
1009
  step: {
1011
1010
  id: string;
@@ -1014,11 +1013,12 @@ declare const PlanExecuteState: _langchain_langgraph.AnnotationRoot<{
1014
1013
  args?: Record<string, unknown> | undefined;
1015
1014
  dependencies?: string[] | undefined;
1016
1015
  };
1017
- error?: string | undefined;
1016
+ success: boolean;
1018
1017
  result?: unknown;
1018
+ error?: string | undefined;
1019
1019
  }[], unknown>;
1020
1020
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1021
- status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1021
+ status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", 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,7 +1253,6 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1253
1253
  confidence?: number | undefined;
1254
1254
  } | undefined;
1255
1255
  pastSteps: {
1256
- success: boolean;
1257
1256
  timestamp: string;
1258
1257
  step: {
1259
1258
  id: string;
@@ -1262,11 +1261,12 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1262
1261
  args?: Record<string, unknown> | undefined;
1263
1262
  dependencies?: string[] | undefined;
1264
1263
  };
1265
- error?: string | undefined;
1264
+ success: boolean;
1266
1265
  result?: unknown;
1266
+ error?: string | undefined;
1267
1267
  }[];
1268
1268
  currentStepIndex: number | undefined;
1269
- status: "completed" | "failed" | "planning" | "executing" | "replanning";
1269
+ status: "failed" | "planning" | "executing" | "replanning" | "completed";
1270
1270
  response: string | undefined;
1271
1271
  error: string | undefined;
1272
1272
  iteration: number;
@@ -1286,7 +1286,6 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1286
1286
  confidence?: number | undefined;
1287
1287
  } | undefined;
1288
1288
  pastSteps?: {
1289
- success: boolean;
1290
1289
  timestamp: string;
1291
1290
  step: {
1292
1291
  id: string;
@@ -1295,11 +1294,12 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1295
1294
  args?: Record<string, unknown> | undefined;
1296
1295
  dependencies?: string[] | undefined;
1297
1296
  };
1298
- error?: string | undefined;
1297
+ success: boolean;
1299
1298
  result?: unknown;
1299
+ error?: string | undefined;
1300
1300
  }[] | undefined;
1301
1301
  currentStepIndex?: number | undefined;
1302
- status?: "completed" | "failed" | "planning" | "executing" | "replanning" | undefined;
1302
+ status?: "failed" | "planning" | "executing" | "replanning" | "completed" | undefined;
1303
1303
  response?: string | undefined;
1304
1304
  error?: string | undefined;
1305
1305
  iteration?: number | undefined;
@@ -1330,7 +1330,6 @@ 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;
1334
1333
  timestamp: string;
1335
1334
  step: {
1336
1335
  id: string;
@@ -1339,10 +1338,10 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1339
1338
  args?: Record<string, unknown> | undefined;
1340
1339
  dependencies?: string[] | undefined;
1341
1340
  };
1342
- error?: string | undefined;
1341
+ success: boolean;
1343
1342
  result?: unknown;
1343
+ error?: string | undefined;
1344
1344
  }[], {
1345
- success: boolean;
1346
1345
  timestamp: string;
1347
1346
  step: {
1348
1347
  id: string;
@@ -1351,11 +1350,12 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1351
1350
  args?: Record<string, unknown> | undefined;
1352
1351
  dependencies?: string[] | undefined;
1353
1352
  };
1354
- error?: string | undefined;
1353
+ success: boolean;
1355
1354
  result?: unknown;
1355
+ error?: string | undefined;
1356
1356
  }[], unknown>;
1357
1357
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1358
- status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1358
+ status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", 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,7 +1386,6 @@ 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;
1390
1389
  timestamp: string;
1391
1390
  step: {
1392
1391
  id: string;
@@ -1395,10 +1394,10 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1395
1394
  args?: Record<string, unknown> | undefined;
1396
1395
  dependencies?: string[] | undefined;
1397
1396
  };
1398
- error?: string | undefined;
1397
+ success: boolean;
1399
1398
  result?: unknown;
1399
+ error?: string | undefined;
1400
1400
  }[], {
1401
- success: boolean;
1402
1401
  timestamp: string;
1403
1402
  step: {
1404
1403
  id: string;
@@ -1407,11 +1406,12 @@ declare function createPlanExecuteAgent<TTool extends PlanExecuteTool = PlanExec
1407
1406
  args?: Record<string, unknown> | undefined;
1408
1407
  dependencies?: string[] | undefined;
1409
1408
  };
1410
- error?: string | undefined;
1409
+ success: boolean;
1411
1410
  result?: unknown;
1411
+ error?: string | undefined;
1412
1412
  }[], unknown>;
1413
1413
  currentStepIndex: _langchain_langgraph.BaseChannel<number | undefined, number | undefined, unknown>;
1414
- status: _langchain_langgraph.BaseChannel<"completed" | "failed" | "planning" | "executing" | "replanning", "completed" | "failed" | "planning" | "executing" | "replanning", unknown>;
1414
+ status: _langchain_langgraph.BaseChannel<"failed" | "planning" | "executing" | "replanning" | "completed", "failed" | "planning" | "executing" | "replanning" | "completed", 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<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
1923
+ status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "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: "completed" | "failed" | "generating" | "reflecting" | "revising";
2218
+ status: "failed" | "completed" | "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?: "completed" | "failed" | "generating" | "reflecting" | "revising" | undefined;
2252
+ status?: "failed" | "completed" | "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<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
2305
+ status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "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<"completed" | "failed" | "generating" | "reflecting" | "revising", "completed" | "failed" | "generating" | "reflecting" | "revising", unknown>;
2362
+ status: _langchain_langgraph.BaseChannel<"failed" | "completed" | "generating" | "reflecting" | "revising", "failed" | "completed" | "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
- reasoning: string;
2424
2423
  timestamp: number;
2424
+ reasoning: string;
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
- reasoning?: string | undefined;
2431
2430
  timestamp?: number | undefined;
2431
+ reasoning?: string | 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
- reasoning: string;
2438
2437
  timestamp: number;
2438
+ reasoning: string;
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
- reasoning?: string | undefined;
2445
2444
  timestamp?: number | undefined;
2445
+ reasoning?: string | 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
- success: boolean;
2503
2502
  result: string;
2503
+ success: boolean;
2504
2504
  workerId: string;
2505
2505
  assignmentId: string;
2506
2506
  completedAt: number;
2507
- error?: string | undefined;
2508
2507
  metadata?: _agentforge_core.JsonObject | undefined;
2508
+ error?: string | undefined;
2509
2509
  }, {
2510
- success: boolean;
2511
2510
  result: string;
2511
+ success: boolean;
2512
2512
  workerId: string;
2513
2513
  assignmentId: string;
2514
2514
  completedAt: number;
2515
- error?: string | undefined;
2516
2515
  metadata?: _agentforge_core.JsonObject | undefined;
2516
+ error?: string | 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
- reasoning: string;
2660
2659
  timestamp: number;
2660
+ reasoning: string;
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
- reasoning?: string | undefined;
2667
2666
  timestamp?: number | undefined;
2667
+ reasoning?: string | 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
- reasoning: string;
2674
2673
  timestamp: number;
2674
+ reasoning: string;
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
- reasoning?: string | undefined;
2681
2680
  timestamp?: number | undefined;
2681
+ reasoning?: string | 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
- reasoning: string;
2689
2688
  timestamp: number;
2689
+ reasoning: string;
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
- success: boolean;
2750
2749
  result: string;
2750
+ success: boolean;
2751
2751
  workerId: string;
2752
2752
  assignmentId: string;
2753
2753
  completedAt: number;
2754
- error?: string | undefined;
2755
2754
  metadata?: _agentforge_core.JsonObject | undefined;
2755
+ error?: string | undefined;
2756
2756
  }, {
2757
- success: boolean;
2758
2757
  result: string;
2758
+ success: boolean;
2759
2759
  workerId: string;
2760
2760
  assignmentId: string;
2761
2761
  completedAt: number;
2762
- error?: string | undefined;
2763
2762
  metadata?: _agentforge_core.JsonObject | undefined;
2763
+ error?: string | undefined;
2764
2764
  }>, "many">;
2765
2765
  reducer: (left: TaskResult[], right: TaskResult[]) => {
2766
- success: boolean;
2767
2766
  result: string;
2767
+ success: boolean;
2768
2768
  workerId: string;
2769
2769
  assignmentId: string;
2770
2770
  completedAt: number;
2771
- error?: string | undefined;
2772
2771
  metadata?: _agentforge_core.JsonObject | undefined;
2772
+ error?: string | 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
- reasoning: string;
2890
2889
  timestamp: number;
2890
+ reasoning: string;
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
- reasoning: string;
2897
2896
  timestamp: number;
2897
+ reasoning: string;
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
- success: boolean;
2920
2919
  result: string;
2920
+ success: boolean;
2921
2921
  workerId: string;
2922
2922
  assignmentId: string;
2923
2923
  completedAt: number;
2924
- error?: string | undefined;
2925
2924
  metadata?: _agentforge_core.JsonObject | undefined;
2925
+ error?: string | undefined;
2926
2926
  }[], {
2927
- success: boolean;
2928
2927
  result: string;
2928
+ success: boolean;
2929
2929
  workerId: string;
2930
2930
  assignmentId: string;
2931
2931
  completedAt: number;
2932
- error?: string | undefined;
2933
2932
  metadata?: _agentforge_core.JsonObject | undefined;
2933
+ error?: string | 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<"completed" | "failed" | "executing" | "initializing" | "routing" | "coordinating" | "aggregating", "completed" | "failed" | "executing" | "initializing" | "routing" | "coordinating" | "aggregating", unknown>;
2948
+ status: _langchain_langgraph.BaseChannel<"failed" | "executing" | "completed" | "initializing" | "routing" | "coordinating" | "aggregating", "failed" | "executing" | "completed" | "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.86",
3
+ "version": "0.16.87",
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.86",
44
+ "@agentforge/core": "0.16.87",
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.86",
50
+ "@agentforge/testing": "0.16.87",
51
51
  "@eslint/js": "^9.17.0",
52
52
  "@types/node": "^22.10.2",
53
53
  "eslint": "^9.17.0",