5 Agentic Workflows with LangGraph
This chapter covers
- Overview of agentic workflows and agents
- LangGraph fundamentals and state management
- Transition from LangChain chains to an agentic workflow
Large language models are driving a new generation of applications that require more than simple prompt-response exchanges. As applications become more complex, agentic workflows have become essential—a pattern where the LLM orchestrates a structured, multi-step process using predefined components and explicit state management. Unlike fully autonomous agents, agentic workflows follow a predictable sequence of steps and do not dynamically select tools or adapt to context in real time. Instead, they offer reliability, transparency, and modularity by guiding the application through a set flow, using the LLM to make decisions within fixed boundaries.
5.1 Understanding Agentic Workflows and Agents
LLM-powered agent-based systems typically follow one of two core design patterns: agentic workflows and agents. Each pattern shapes how the application operates, as illustrated in figure 5.1. Because these terms are often used interchangeably—but have important differences—it’s essential to understand exactly what is meant by “agentic workflow” and “agent” before diving deeper..