Agent and multi-agent systems are all about how the different components of the the system communicate with each other. We spend a lot of time thinking about the best infrastructure and developer experience for facilitating this type of communication. Today, we’re excited to announce Command: a new tool in langgraph to more easily facilitate multi-actor (or multi-agent) communication.
Our agent framework langgraph is powered by an event-driven system. We expose a graph-based developer experience heavily influenced by NetworkX, which we've found maps nicely to developer’s mental models of agents. Given the underlying event-driven architecture, we can easily add variants of this graph-based devX.
langgraph graphs have traditionally been represented as nodes and edges. This declarative architecture is helpful for mapping an agent’s path to a visual representation. On the flip side, requiring edges to connect nodes can sometimes make it harder or unintuitive to express more dynamic logic. In these situations, you would want nodes to be able to specify dynamically which node to go to next.
With this in mind, we are excited to release Command in LangGraph. This is a special type that when returned from a node specifies not only the update to the state (as usual) but also which node to go to next. This allows nodes to more directly control which nodes are executed after-the-fact.