How jwuthri-cloud/tracely-ai works
Tracely turns production agent traces into graded failures, regression cases, CI gate results, and alerts. The main path is OTLP ingestion, online evaluation and failure triage, case promotion and replay, then gate decisions and notifications. The graph also preserves documented analysis, calibration, and conversation views. Some subsystem links come from README descriptions because their implementation was not sampled; those are marked dashed when the code-level caller is not evidenced.
Main entry points: ingestion_service.py Trace ingestion · tasks.py Background tasks · evaluation_service.py Online evaluation · gate_service.py CI gate
Components 28
Trace ingestion
- Tracing SDK
sdk/tracely_sdk/__init__.py - OTLP endpoint
backend/tracely/api/routers/otlp.py - Trace ingestion
backend/tracely/services/ingestion_service.py
Evaluation and triage
- Online evaluation
backend/tracely/services/evaluation_service.py - LLM gateway
backend/tracely/infrastructure/llm/provider.py - Evaluation scores
backend/tracely/infrastructure/clickhouse/score_writer.py - Failure clustering
backend/tracely/services/failure_intel_service.py
Regression and gates
- Regression cases
backend/tracely/domain/regression - CI gate
backend/tracely/services/gate_service.py - Conversation scenarios
backend/tracely/domain/simulation
Product insights
- Alert monitoring
backend/tracely/services/monitoring_service.py - Alert flow actions
backend/tracely/services/alert_flow_service.py - Notifications
backend/tracely/infrastructure/notifications/dispatch.py - Trends and analysis
backend/tracely/domain/analysis/statistics.py - Judge calibration
backend/tracely/domain/evaluation/calibration.py
API and persistence
- Raw trace blobs
backend/tracely/infrastructure/blob/s3.py - Background tasks
backend/tracely/workers/tasks.py - Trace event store
backend/tracely/infrastructure/clickhouse/client.py - Trace queries
backend/tracely/infrastructure/clickhouse/trace_reader.py - API application
backend/tracely/api/main.py - Workspace registry
backend/tracely/infrastructure/db/repositories.py - Registry models
backend/tracely/infrastructure/db/models.py - Database sessions
backend/tracely/infrastructure/db/engine.py - Runtime settings
backend/tracely/config.py
Other components
- Agent workload
- Product UI
frontend/app/(app)/traces/page.tsx - Developer / CI
- Slack, email, webhook
Connections 30
- Agent workload → Tracing SDK: emits traces
README.md - Tracing SDK → OTLP endpoint: sends OTLP
README.md - API application → OTLP endpoint: mounts route
backend/tracely/api/main.py - OTLP endpoint → Trace ingestion: submits traces
- Trace ingestion → Raw trace blobs: stores raw body
backend/tracely/infrastructure/blob/s3.py - Trace ingestion → Background tasks: enqueues work
backend/tracely/services/ingestion_service.py - Background tasks → Trace ingestion: processes blob
backend/tracely/workers/tasks.py - Trace ingestion → Trace event store: writes events
backend/tracely/services/ingestion_service.py - Background tasks → Online evaluation: dispatches grading
backend/tracely/workers/tasks.py - Online evaluation → Trace queries: loads traces
backend/tracely/services/evaluation_service.py - Online evaluation → LLM gateway: runs judges
backend/tracely/services/evaluation_service.py - Online evaluation → Evaluation scores: writes scores
backend/tracely/services/evaluation_service.py - Background tasks → Failure clustering: dispatches triage
backend/tracely/workers/tasks.py - Failure clustering → Regression cases: promotes failures
README.md - Developer / CI → CI gate: runs CI gate
README.md - CI gate → Regression cases: replays cases
backend/tracely/services/gate_service.py - CI gate → Conversation scenarios: runs scenarios
backend/tracely/services/gate_service.py - CI gate → Developer / CI: reports verdict
README.md - Background tasks → Alert monitoring: evaluates monitors
backend/tracely/workers/tasks.py - Alert monitoring → Alert flow actions: fires alert flow
backend/tracely/services/monitoring_service.py - Alert flow actions → Notifications: dispatches actions
README.md - Notifications → Slack, email, webhook: delivers alerts
README.md - Product UI → Online evaluation: requests grading
README.md - Product UI → Judge calibration: labels verdicts
README.md - Product UI → Trends and analysis: views trends
README.md - API application → Workspace registry: serves product data
- Workspace registry → Registry models: queries entities
backend/tracely/infrastructure/db/repositories.py - Database sessions → Workspace registry: provides sessions
- Trace ingestion → Runtime settings: reads settings
backend/tracely/services/ingestion_service.py - Database sessions → Runtime settings: configures engines
backend/tracely/infrastructure/db/engine.py