langgraph 0.2.4
Summary of Changes
- Improved documentation for
Sendclass, clarifying its role inStateGraphconditional edges for flexible state management in workflows #1280 - Updated examples in prebuilt modules to use
StateGraphinstead of deprecatedMessageGraph#1330 - Fixed several bugs in the Pregel engine related to task processing and checkpointing
- Improved error logging during task retries with more detailed exception information
Detailed Changes
langgraph.types.Send
- Enhanced documentation to better explain that
Sendcan be used to dynamically invoke a node with a custom state at the next step - Clarified that the sent state can differ from the core graph's state, allowing for flexible workflow management
- Added more descriptive example comments for "map-reduce" workflow patterns
langgraph.pregel.Pregel
- Modified state handling to properly manage Context channels by replacing them with LastValue channels when getting state
- Fixed how task names are extracted in state snapshots
- Improved checkpoint handling with better debug output generation
- Removed redundant input field from PregelTaskDescription to simplify task management
langgraph.pregel.retry
- Enhanced error logging during retries to include full exception information, making debugging easier