std1.0.0-beta-7 SafeC docs

std :: ml::llm

Type alias std::GraphNodeFn

#include <std/ml/llm.h> source

typedef fn struct Value(const &Value state) GraphNodeFn

Named nodes transform a shared Value state; each node either always advances to a fixed 'nextNode', or (if 'router' is set) calls 'router' on the post-node state to pick the next node by name. Graph::run() starts at the graph's entry node and keeps following edges until a node returns/routes to "end", a named node isn't found (also treated as end), or 'maxSteps' is hit (guards against an accidental infinite loop in a misconfigured graph).