Fetch events
trace_id:
Print a visual tree
parent_run_id relationships and colorized by event category.
Build tree data programmatically
Get an LLM-friendly tree string
Notes
- Tree methods rely on persisted rows in
agent_logs. - Call
flush()before tree inspection when using manual spans.