Building a LangGraph agent: state instead of longer prompts
Linear RAG breaks down as soon as the solution path is not known up front. LangGraph swaps the chain for a stateful graph: a shared state object, nodes that update it, and conditional edges that pick the next step at runtime.