fix(deepresearch): fix ResearchTeamNode error and missing edge from research_team to planner, preventing possible infinite loop#21
Conversation
…esearch_team to planner, preventing possible infinite loop
|
I have some questions about when curPlan becomes empty. |
@benym When I config to use other LLMs, I may encounter situations where curPlan is null or empty list, and this phenomenon does not occur consistently. |
|
From the call path perspective, even if the output during Plan deserialization is indeed null, when it reaches ResearchTeamNode, |
本PR修复以下问题:
ResearchTeamNode目前的逻辑会造成进入parallel_executor后可能出现curPlan为null的现象,且可能因此造成research_team_next_node一直为parallel_executor而造成流程进入research_team后死循环。ResearchTeamDispatcher,默认的情况下路径会进到planner,而DeepResearchConfiguration中从research_team出发的conditionalEdge缺少planner的mapping,因此也会造成流程无法运行到END。This PR addresses and fixes the following issues:
ResearchTeamNode's current logic can lead to a scenario wherecurPlanbecomesnullafter entering theparallel_executor. This can subsequently cause theresearch_team_next_nodeto perpetually remain theparallel_executor, resulting in a deadlock once the flow enters theresearch_team.ResearchTeamDispatcher, the default path leads to theplanner. However, theDeepResearchConfigurationis missing theplannermapping in the conditional edge starting from theresearch_team, which also prevents the flow from reachingEND.