Utilities for working with agent trees (hierarchies of agents and sub-agents).
Summary
Functions
Builds a map from child agent name to parent agent.
Finds an agent by name using depth-first search.
Validates that all agent names in the tree are unique.
Functions
Builds a map from child agent name to parent agent.
Finds an agent by name using depth-first search.
Returns {:ok, agent} if found, :error otherwise.
Validates that all agent names in the tree are unique.
Returns {:ok, names} where names is the set of all names,
or {:error, reason} if duplicates are found.