Commit c3af893
fix(graph): fix cyclic graph behavior (strands-agents#768)
fix a bug in the Graph multiagent pattern where the reset_on_revisit feature fails to enable cycles and feedback loops. The issue was in the _find_newly_ready_nodes method, which filtered out completed nodes before they could be revisited, making it impossible to implement feedback loops even when reset_on_revisit=True.
---------
Co-authored-by: Murat Kaan Meral <murmeral@amazon.nl>Co-authored-by: Mackenzie Zastrow <zastrowm@users.noreply.github.com>1 parent b10d9f3 commit c3af893
File tree
2 files changed
+266
-77
lines changed- src/strands/multiagent
- tests/strands/multiagent
2 files changed
+266
-77
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
469 | 469 | | |
470 | 470 | | |
471 | 471 | | |
472 | | - | |
473 | | - | |
474 | | - | |
475 | | - | |
476 | | - | |
| 472 | + | |
477 | 473 | | |
478 | 474 | | |
479 | 475 | | |
480 | 476 | | |
481 | 477 | | |
482 | | - | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
483 | 481 | | |
484 | | - | |
| 482 | + | |
485 | 483 | | |
486 | 484 | | |
487 | 485 | | |
488 | | - | |
489 | | - | |
490 | | - | |
491 | | - | |
492 | | - | |
| 486 | + | |
493 | 487 | | |
494 | 488 | | |
495 | 489 | | |
496 | | - | |
| 490 | + | |
497 | 491 | | |
498 | 492 | | |
499 | 493 | | |
500 | 494 | | |
501 | | - | |
502 | | - | |
503 | | - | |
504 | 495 | | |
505 | 496 | | |
506 | | - | |
| 497 | + | |
507 | 498 | | |
508 | 499 | | |
509 | 500 | | |
| |||
0 commit comments