Returns a handler function that processes pending tool calls in the state.
Note
These functions are for manual tool dispatch in custom node handlers.
When using Agent objects with ellmer, tool calling is handled
internally by ellmer's Chat class. See react_graph for the
recommended pattern.
See also
Other node-helpers:
as_node(),
route_to(),
route_tool_calls()
Examples
if (FALSE) { # \dontrun{
tools <- list(add = function(a, b) a + b)
handler <- tool_node(tools)
} # }