|
NeoGraph 0.10.0
A C++17 Graph Agent Engine Library — LangGraph for C++
|
Node that dispatches and executes pending tool calls. More...
#include <node.h>
Public Member Functions | |
| std::string | get_name () const override |
| Get the node's unique name within the graph. | |
| asio::awaitable< NodeOutput > | run (NodeInput in) override |
v0.4 PR 9a: unified run — finds the latest assistant message with tool_calls, dispatches each call to the matching Tool, writes tool result messages back to the messages channel. | |
| ToolDispatchNode (const std::string &name, const NodeContext &ctx) | |
| Construct a tool dispatch node. | |
Node that dispatches and executes pending tool calls.
Reads the last assistant message from the "messages" channel, executes each tool call, and writes tool result messages back.
Deliberately does NOT override execute_stream: tool execution is synchronous work against the user's Tool implementations and produces no LLM token stream to emit. The default execute_stream inherited from GraphNode falls through to execute(), which is the intended behaviour. Emit your own progress events from inside your Tool if you need fine-grained observability.
| neograph::graph::ToolDispatchNode::ToolDispatchNode | ( | const std::string & | name, |
| const NodeContext & | ctx | ||
| ) |
Construct a tool dispatch node.
| name | Unique node name within the graph. |
| ctx | Node context providing available tools. |
|
inlineoverridevirtual |
Get the node's unique name within the graph.
Implements neograph::graph::GraphNode.