Pattern Proposal: Telemetry-Observable Agent Steps
Summary
Instruments pipeline execution and agent interactions with OpenTelemetry to track latency, token usage, and step errors.
Candidate Pattern
- ID:
telemetry-observable-agent-steps - Classification: intelligence
- Maturity: established
- Type: implemented
Observed Signals
No specific signals listed.
Evidence
Supporting Evidence
- pyproject.toml - Includes opentelemetry-api and opentelemetry-sdk dependencies.
- src/cas_runner/governance/models.py (TraceableMetric) - Encapsulates metric records carrying trace context.
Scope Assessment
- Evidence Strength: high
- Confidence: high
- Applies to: ideas-to-life-cas
Rationale
- Intent: Provide comprehensive visibility into the latency, cost, and error boundaries of agentic runs.
- Context: Integrated via OpenTelemetry SDK dependencies configured in the runner runtime.
- Force: Multi-step agent pipelines suffer from opacity when failures occur inside nested LLM calls
- Force: Debugging cost spikes and slow steps requires distributed trace context
Traceability
Artifact source: proposed-patterns