@agentforge/patterns 0.10.6 → 0.11.0

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.cjs CHANGED
@@ -471,7 +471,7 @@ function createActionNode(tools, verbose = false, enableDeduplication = true) {
471
471
  }
472
472
  try {
473
473
  const startTime2 = Date.now();
474
- const result = await tool.execute(action.arguments);
474
+ const result = await tool.invoke(action.arguments);
475
475
  const executionTime = Date.now() - startTime2;
476
476
  toolsExecuted++;
477
477
  actionLogger.debug("Tool executed successfully", {
@@ -1127,7 +1127,7 @@ function createExecutorNode(config) {
1127
1127
  (_, reject) => setTimeout(() => reject(new Error("Step execution timeout")), stepTimeout)
1128
1128
  );
1129
1129
  result = await Promise.race([
1130
- tool.execute(currentStep.args || {}),
1130
+ tool.invoke(currentStep.args || {}),
1131
1131
  timeoutPromise
1132
1132
  ]);
1133
1133
  const executionTime = Date.now() - startTime;
@@ -2622,7 +2622,8 @@ function createSupervisorNode(config) {
2622
2622
  activeAssignments: assignments,
2623
2623
  // Multiple assignments for parallel execution!
2624
2624
  messages,
2625
- iteration: state.iteration + 1
2625
+ // Add 1 to iteration counter (uses additive reducer)
2626
+ iteration: 1
2626
2627
  };
2627
2628
  } catch (error) {
2628
2629
  logger2.error("Supervisor node error", {
package/dist/index.js CHANGED
@@ -368,7 +368,7 @@ function createActionNode(tools, verbose = false, enableDeduplication = true) {
368
368
  }
369
369
  try {
370
370
  const startTime2 = Date.now();
371
- const result = await tool.execute(action.arguments);
371
+ const result = await tool.invoke(action.arguments);
372
372
  const executionTime = Date.now() - startTime2;
373
373
  toolsExecuted++;
374
374
  actionLogger.debug("Tool executed successfully", {
@@ -1024,7 +1024,7 @@ function createExecutorNode(config) {
1024
1024
  (_, reject) => setTimeout(() => reject(new Error("Step execution timeout")), stepTimeout)
1025
1025
  );
1026
1026
  result = await Promise.race([
1027
- tool.execute(currentStep.args || {}),
1027
+ tool.invoke(currentStep.args || {}),
1028
1028
  timeoutPromise
1029
1029
  ]);
1030
1030
  const executionTime = Date.now() - startTime;
@@ -2519,7 +2519,8 @@ function createSupervisorNode(config) {
2519
2519
  activeAssignments: assignments,
2520
2520
  // Multiple assignments for parallel execution!
2521
2521
  messages,
2522
- iteration: state.iteration + 1
2522
+ // Add 1 to iteration counter (uses additive reducer)
2523
+ iteration: 1
2523
2524
  };
2524
2525
  } catch (error) {
2525
2526
  logger2.error("Supervisor node error", {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agentforge/patterns",
3
- "version": "0.10.6",
3
+ "version": "0.11.0",
4
4
  "description": "Agent patterns (ReAct, Planner-Executor) for AgentForge framework",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",