Framework · Orchestration Frameworks

Dendron

Dendron is a Python library for programming LLM agents as behavior trees whose leaves are model and tool actions composed by control nodes.

Description

Dendron is a library for building software agents using behavior trees and language models. Leaf action nodes wrap LLM calls (CausalLMAction, ImageLMAction, LogLikelihoodAction) and tools, and they are composed by control nodes such as Sequence and Fallback. Every behavior tree has an associated Blackboard, a key-value store accessible by all nodes, which is the mechanism by which nodes share state since they otherwise communicate only by ticking children and returning a NodeStatus.

Solution

An agent is expressed as a behavior tree. The root is ticked, control nodes such as Sequence and Fallback tick their children in order, and leaf action nodes run an LLM call or tool and return a NodeStatus of SUCCESS, FAILURE, or RUNNING. Nodes that need to share information beyond status read and write a shared Blackboard key-value store attached to the tree.

Primary use cases

  • composing LLM agents as behavior trees
  • reactive control flow over model and tool actions
  • reusing simple behaviors as larger agent programs
  • structured programming of language model agents

Open the full interactive page

Diagram, neighbourhood map, code examples, related patterns and full provenance.