Documentation Index
Fetch the complete documentation index at: https://docs.galileo.ai/llms.txt
Use this file to discover all available pages before exploring further.
GalileoTracingProcessor
OpenAI Agents TracingProcessor for logging traces to Galileo.
Builds a tree of spans during agent execution and logs them hierarchically
to Galileo upon trace completion.
Arguments
-
_galileo_logger (GalileoLogger): The Galileo logger instance.
-
_flush_on_trace_end (bool): Whether to automatically flush the log batch to Galileo when a trace ends.
-
_nodes (dict[str, Node]): Stores Node objects keyed by their OpenAI span_id or trace_id (for root).
add_galileo_custom_span
def add_galileo_custom_span(span: GalileoSpan) -> Span[GalileoCustomSpan]
Add a Galileo custom span to the trace.
force_flush
def force_flush(self) -> None
Forces an immediate flush of all queued traces/spans.
on_span_end
def on_span_end(self, span: Span[Any]) -> None
Called when an OpenAI Agent span ends.
on_span_start
def on_span_start(self, span: Span[Any]) -> None
Called when an OpenAI Agent span starts.
on_trace_end
def on_trace_end(self, trace: Trace) -> None
Called when an OpenAI Agent trace ends.
on_trace_start
def on_trace_start(self, trace: Trace) -> None
Called when an OpenAI Agent trace starts.
shutdown
def shutdown(self) -> None
Called when the application stops. Flushes any remaining logs.