mirror of
https://gitee.com/wanwujie/deer-flow
synced 2026-04-10 01:04:46 +08:00
fix: remove the unnessary conditional edge. (#671)
This commit is contained in:
@@ -63,12 +63,6 @@ def _build_base_graph():
|
||||
["planner", "researcher", "coder"],
|
||||
)
|
||||
builder.add_edge("reporter", END)
|
||||
# Add conditional edges for coordinator to handle clarification flow
|
||||
builder.add_conditional_edges(
|
||||
"coordinator",
|
||||
lambda state: state.get("goto", "planner"),
|
||||
["planner", "background_investigator", "coordinator", END],
|
||||
)
|
||||
return builder
|
||||
|
||||
|
||||
|
||||
@@ -96,8 +96,8 @@ def test_build_base_graph_adds_nodes_and_edges(MockStateGraph):
|
||||
# Check that all nodes and edges are added
|
||||
assert mock_builder.add_edge.call_count >= 2
|
||||
assert mock_builder.add_node.call_count >= 8
|
||||
# Now we have 2 conditional edges: research_team and coordinator
|
||||
assert mock_builder.add_conditional_edges.call_count == 2
|
||||
# Now we have 1 conditional edges: research_team
|
||||
assert mock_builder.add_conditional_edges.call_count == 1
|
||||
|
||||
|
||||
@patch("src.graph.builder._build_base_graph")
|
||||
|
||||
Reference in New Issue
Block a user