State Loss in Hierarchical Multi-Agent System with Deep Agents and Custom AgentState

Hi @syd ,

Thank you so much, that helped. :slightly_smiling_face:

Found a similar solution in this post as well: Deep Agents: Custom state fields not accessible in ToolRuntime.state - OSS Product Help / LangGraph - LangChain Forum.

In addition, if you want to access a variable across multiple agents and tools, you can also store it in runtime.store and later retrieve it. This can slightly reduce the latency and complexity in my opinion.

1 Like