-
|
In the Strands Agents Graph documentation, the Feedback Loop example shows this pattern: builder = GraphBuilder()
builder.add_node(draft_writer, "draft_writer")
builder.add_node(reviewer, "reviewer")
builder.add_node(publisher, "publisher")
builder.add_edge("draft_writer", "reviewer")
builder.add_edge("reviewer", "draft_writer", condition=needs_revision)
builder.add_edge("reviewer", "publisher", condition=is_approved)The intended flow is: My question is about what input The Did I understand it correctly? If the publisher needs the actual draft content, would the correct approach be to add an additional conditional edge from |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
|
Yes, your understanding is correct. We check the results of all the incoming edges where condition is satisfied. See related code in graph.py if you need the raw draft content directly available to the publisher, adding a conditional edge from draft_writer → publisher (with the same is_approved condition) is the right approach. |
Beta Was this translation helpful? Give feedback.

Yes, your understanding is correct. We check the results of all the incoming edges where condition is satisfied. See related code in graph.py
if you need the raw draft content directly available to the publisher, adding a conditional edge from draft_writer → publisher (with the same is_approved condition) is the right approach.