TraceEvent#
Module: agent_framework.tracing
- class agent_framework.tracing.TraceEvent(event_id, parent_event_id, span_id, parent_span_id, timestamp, channel, level, kind, title, summary='', context=<factory>, payload=<factory>, tags=())[source]#
Bases:
objectA single trace row on the unified bus.
Semantics by channel:
runtime,llm,user: agent / model / user-interaction spans. Typically carryspan_id,parent_span_id, and richTraceContext(run_id,agent_id, …).log: Pythonloggingoutput. Flat record shape;span_idandparent_span_idstayNone;contextshould only carrysession_idwhen needed for routing.
- Parameters:
event_id (str)
parent_event_id (str | None)
span_id (str | None)
parent_span_id (str | None)
timestamp (str)
channel (Literal['runtime', 'llm', 'log', 'user'])
level (Literal['debug', 'info', 'warning', 'error'])
kind (str)
title (str)
summary (str)
context (TraceContext)
payload (dict[str, Any])
tags (tuple[str, ...])
- event_id: str#
- parent_event_id: str | None#
- span_id: str | None#
- parent_span_id: str | None#
- timestamp: str#
- channel: Literal['runtime', 'llm', 'log', 'user']#
- level: Literal['debug', 'info', 'warning', 'error']#
- kind: str#
- title: str#
- summary: str#
- context: TraceContext#
- payload: dict[str, Any]#
- tags: tuple[str, ...]#
- with_context(overlay)[source]#
- Parameters:
overlay (TraceContext)
- Return type: