█

AI/TLDR

Buy me a coffee
Buy me a coffee

Tracely

Trace-native CI/CD for AI agents: failing production traces become replayable regression tests that gate pull requests

Evaluation & Red-TeamingOpen source
Language
Python
License
MIT
IN SHORT

What is Tracely?

Tracely is an open-source platform that turns production failures of AI agents into regression tests. It sits in the Evaluation & Red-Teaming category of the Evaluation & Production Ops tools and is open-source, written in Python and licensed MIT. To get started: run the whole stack with demo data.

Overview

Tracely is an open-source platform that turns production failures of AI agents into regression tests. It ingests agent traces over OTLP, grades each run as it lands with structural checks and LLM judges, groups failures into issues, and lets you promote a failing trace into a hermetic test case that is replayed on every pull request. Its README frames the idea as "the recorded run is the test": instead of hand-authoring an eval dataset, the exact input, tool calls and model responses of a real failure become the fixture.

Tracely dashboard with trace, failure-cluster, auto-failure and regression-case counts, last-24-hour latency and cost, the biggest failure clusters and recent regression cases
One workspace: what ran, what broke and what is already pinned as a test.Tracely README ↗

The workflow has five stages, each a page in the app. Observe shows traces as conversation threads with agent semantics (agent, conversation, turn, step) stored as indexed columns and evaluators shown as columns on the trace table. Detect and triage clusters failures structurally and semantically. Test promotes a failure into a case with a fail-to-pass contract, or into a multi-turn or adversarial red-team scenario. Ship runs the suite in CI through the tracely CLI or a GitHub Action that posts a commit status and a PR comment. Alerts are drawn as flows that can post to Slack, email or a webhook and include an LLM step.

The whole product (FastAPI backend, Celery workers, Next.js UI, Python SDK and CI gate CLI) is MIT licensed and self-hostable with Docker Compose, backed by ClickHouse, Postgres with pgvector, Redis and MinIO. The project states that its write path mirrors Langfuse's design, reimplemented in Python. A hosted service is offered at tracely-ai.com with a free tier, and every backend also serves an MCP endpoint so a coding agent can read traces and create evaluators.

What it does

  • OTLP/HTTP ingestion from any language plus a Python SDK (tracely-ai) that auto-instruments OpenAI, Anthropic, Google, Mistral and LangChain calls
Tracely trace timeline showing agent, thinking, skill, generation, delegate and retriever spans for a conversation, with a nested researcher sub-agent and the selected span's input
A trace waterfall with a nested sub-agent and the selected span's input.
Tracely failure clusters page listing auto-detected failures grouped into open issues with occurrence counts
Failures grouped into issues with occurrence counts.
Tracely regression case page for a planner agent marked promoted and fail-to-pass validated, with assertions, a reference trajectory and replay results
A promoted regression case with its fail-to-pass contract, assertions and replay history.
  • Evaluators as columns on the trace table: structural checks with no model, and LLM judges at conversation, run or span level, with scores streamed live and a judge-calibration screen for comparing verdicts with human labels
  • Failure clustering by structural signature and semantic embedding, with suggested evaluators and one-click promotion to a regression case
  • Hermetic regression cases that bundle the recorded input and tool/LLM outputs as fixtures with a fail-to-pass contract, plus scripted and adversarial red-team scenarios
  • CI gating via tracely simulate / replay / gate and a GitHub Action: non-zero exit, commit status and an upserted PR comment, with replay against recorded fixtures needing no API keys
  • Alert flows (gate failed, conversation failed, new failure mode, rate thresholds) routed to Slack, email or webhooks, an in-app assistant and an MCP endpoint at /mcp
Tracely alert flow builder wiring a CI-gate-failed trigger through a condition and an LLM prompt step to a Slack message, with the step inspector and a rule assistant
Alerts drawn as a flow: gate failed, condition, LLM triage note, Slack.Tracely README ↗

Getting started

The README's quickstart needs Docker and Docker Compose. It brings up the full stack with demo data, then shows how to send traces from Python and gate pull requests in GitHub Actions.

Run the whole stack with demo data

This starts ClickHouse, Postgres, Redis and MinIO, runs migrations, seeds a default project with the ingest key tracely_dev_key and populates traces, clusters, cases and gates. The web app is on port 3001 and the backend on port 8000 (remap with TRACELY_WEB_PORT / TRACELY_BACKEND_PORT).

bashbash
git clone https://github.com/jwuthri-cloud/Tracely-ai && cd Tracely-ai
docker compose --profile demo up -d --build --wait
open http://localhost:3001

Send your first trace

Install the SDK with the extra for your provider ([openai], [anthropic], [langchain] or [all]), initialize it once, and wrap a run. Provider calls inside the block are captured as GENERATION spans with model, messages, tokens, latency, tool calls and cost. Any OTLP/HTTP exporter can post to {endpoint}/v1/traces instead.

pythonpython
pip install "tracely-ai[openai]"

import tracely_sdk as tracely

tracely.init(
    endpoint="http://localhost:8000",
    api_key="tracely_dev_key",
    service_name="support-agent",
    env="prod",
    instrument="auto",
)

with tracely.trace(agent="support-agent", conversation="conv-1", user="u_42"):
    client.chat.completions.create(
        model="gpt-4o",
        messages=[{"role": "user", "content": "Where is order ORD-4471?"}],
    )
Tracely CI gate run marked FAIL for the planner agent on a pull request, with passed, failed and skipped counts and the failing case
A failing CI gate run for a pull request.Tracely README ↗

Gate pull requests in CI

Once failures are promoted to cases or scenarios, add the GitHub Action. In this mode Tracely calls your registered agent endpoint and runs its scenarios; the README also documents gating the traces your CI already emits (mode: gate) and hermetic replay with tracely replay.

yamlyaml
      - uses: jwuthri-cloud/Tracely-ai/.github/actions/tracely-gate@master
        with:
          api:   https://tracely.your-co.dev
          key:   ${{ secrets.TRACELY_KEY }}

Or replay recorded cases against your code

Replay re-runs your agent on each promoted case's recorded input and serves the recorded tool and model outputs as fixtures, so it is deterministic and makes no model calls. It requires routing tool and model calls through the SDK's call_tool / call_llm seam; add --live to make real calls.

bashbash
pip install tracely-ai
tracely replay planner --entrypoint my_pkg.agent:run

Connect a coding agent over MCP

Every backend serves an MCP endpoint at /mcp scoped to the ingest key's workspace. The project also publishes an agent skill: npx skills add https://github.com/jwuthri-cloud/Tracely-ai --skill tracely.

bashbash
claude mcp add --transport http tracely http://localhost:8000/mcp \
  --header "Authorization: Bearer tracely_dev_key"

Commands and code are distilled from the project's own documentation — always check the official repo for the latest.

When to use it

  • Stop a known agent failure from shipping again by promoting the failing production trace to a regression case that blocks the pull request reintroducing it
  • Run agent regression suites in CI at no model cost by replaying recorded tool and LLM outputs instead of calling live APIs
  • Triage large volumes of agent failures by clustering them into issues with counts rather than reading individual traces
  • Self-host agent tracing, LLM-judge evaluation and alerting on your own infrastructure under an MIT licence

How Tracely compares

Tracely alongside other open-source evaluation & red-teaming tools AI/TLDR tracks, ranked by GitHub stars.

ToolStarsWhat it does
Strix★ 78.4kStrix runs autonomous AI agents that act like hackers, dynamically running your code to find vulnerabilities and validate them with real proof-of-concepts.
iFixAi★ 47.6kAn agent auditor that runs up to 60 inspections across fabrication, manipulation, deception, unpredictability and opacity, and returns an A–F grade judged by a model from a different vendor.
promptfoo★ 27.9kA developer-first CLI and library for testing and comparing prompts and models, with red-teaming probes for prompt injection, PII leaks, and other vulnerabilities.
OpenAI Evals★ 19.8kA framework and open registry for building and running evaluations of LLMs and LLM-based systems, including prompt chains and tool-using agents.
DeepEval★ 19.7kAn open-source Python framework that tests LLM apps like unit tests, with 50+ metrics for RAG, agents, chatbots, and safety, and a Pytest integration for CI/CD.
Ragas★ 16.5kAn evaluation toolkit focused on retrieval-augmented generation that scores answer faithfulness, context precision/recall, and relevancy, often without needing ground-truth labels.
Arize Phoenix★ 12.5kAn open-source observability and evaluation tool for tracing LLM and agent behavior, running evals on traces, and troubleshooting issues in development and production.
Tracely★ 844Trace-native CI/CD for AI agents: failing production traces become replayable regression tests that gate pull requests