Skip to content

0.2.33

Choose a tag to compare

@github-actions github-actions released this 02 Oct 17:50
7ecc672

langgraph 0.2.33

Summary of Changes

  • Added InjectedStore annotation for injecting LangGraph store objects into tool arguments (#1968)
  • Enhanced ToolNode to support automatic store injection for tools with InjectedStore annotations (#1968)
  • Improved RunnableCallable to better handle keyword arguments, allowing them to override config values (#1968)

Detailed Changes

langgraph.prebuilt.tool_node.InjectedStore

  • Added new InjectedStore class that allows injecting the LangGraph store into tool arguments (#1968)
  • Similar to InjectedState, this annotation hides parameters from the tool-calling model
  • Allows tools to access and manipulate store data directly

langgraph.prebuilt.tool_node.ToolNode

  • Added support for automatic store injection when tools have arguments annotated with InjectedStore (#1968)
  • Optimized tool argument processing by precomputing and caching state and store arguments
  • Refactored _inject_state method and added new methods _inject_store and _inject_tool_args
  • Added store parameter to _func and _afunc methods
  • Enhanced invoke and ainvoke methods to handle the store parameter

langgraph.utils.runnable.RunnableCallable

  • Improved handling of keyword arguments in invoke and ainvoke methods (#1968)
  • Keyword arguments can now override config values instead of being ignored
  • Added check to use provided keyword args before falling back to config values
  • Fixed error logic to consider both config and direct kwargs for required parameters