compass.common.base.setup_async_decision_tree#
- setup_async_decision_tree(graph_setup_func, usage_sub_label=None, **kwargs)[source]#
Setup an
AsyncDecisionTreefor ordinance extraction- Parameters:
graph_setup_func (
callable()) – Factory that returns a fully configurednetworkx.DiGraph.usage_sub_label (
str, optional) – Optional usage label reported to the LLM usage tracker.**kwargs – Keyword arguments forwarded to
graph_setup_func.
- Returns:
AsyncDecisionTree– Decision tree wrapping the graph produced bygraph_setup_func.
Notes
The function asserts that the tree has recorded at least the system prompt before returning the constructed wrapper.