observability.processor.trace_conversion.span_extractor#
Attributes#
Functions#
|
Extract token usage information from a span. |
|
Extract usage information from a span. |
|
Extract timestamp from a span. |
Module Contents#
- logger#
- extract_token_usage(
- span: nat.data_models.span.Span,
Extract token usage information from a span.
- Args:
span (Span): The span to extract token usage from
- Returns:
TokenUsageBaseModel: The token usage information
- extract_usage_info(
- span: nat.data_models.span.Span,
Extract usage information from a span.
- Args:
span (Span): The span to extract usage information from
- Returns:
UsageInfo: The usage information
- extract_timestamp(span: nat.data_models.span.Span) int#
Extract timestamp from a span.
- Args:
span (Span): The span to extract timestamp from
- Returns:
int: The timestamp