get_spans_summary
Aggregate summary statistics for LLM log spans within a time range, returning total cost, tokens, request count, and evaluator scores to monitor usage without retrieving individual spans.
Instructions
Retrieve aggregated summary statistics for log spans. Returns total_count, total_cost, total_tokens, avg_latency etc.
Useful for getting quick insights into your LLM usage without fetching all individual spans.
PARAMETERS:
start_time: Start time in ISO 8601 format (required)
end_time: End time in ISO 8601 format (required)
filters: Optional object of server-side filters in backend format: { field_name: { operator, value } }
RESPONSE FIELDS:
total_cost: Total cost in USD for all filtered spans
total_tokens: Total tokens (prompt + completion)
number_of_requests: Total number of requests matching filters
scores: Aggregated score summaries grouped by evaluator_id
EXAMPLE: { "start_time": "2025-01-01T00:00:00Z", "end_time": "2025-01-31T23:59:59Z", "filters": { "model": { "operator": "", "value": ["gpt-4o"] } } }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filters | No | Server-side filters in backend format. Example: { "model": { "operator": "", "value": ["gpt-4o"] } } | |
| end_time | Yes | End time in ISO 8601 format | |
| start_time | Yes | Start time in ISO 8601 format |