agent-tracedown
The Python SDK for Tracedown, the flight recorder for AI agents. When an agent fails, Tracedown finds the step that caused it, not just the step that crashed. Then you can replay the run with your fix.
pip install agent-tracedown # the SDK: no dependencies
pip install agent-tracedown-server # root-cause analysis, importers, server and UI
import agent_tracedown as tdn
tdn.init(project="support-bot", endpoint="http://localhost:7070")
with tdn.run("CalendarAssistant", input=user_msg) as run:
out = tdn.llm_call(call_model, model="gpt-4o-mini", prompt=messages)
result = tdn.tool_call("calendar_create_event", args, create_event)
run.output(answer)
There is one-line instrumentation for LangGraph, the OpenAI Agents SDK, the Claude Agent SDK, Google ADK, Pydantic AI, MCP, CrewAI, AutoGen, Semantic Kernel and LlamaIndex (agent_tracedown.integrations). Runs can also be exported to any OpenTelemetry collector.
One-line run tracing
For a single-function agent, use @tdn.traced_run(name) instead of opening the
run context yourself. The decorator records the first argument as input, the
return value as output, and re-raises exceptions after marking the run failed.
It supports both synchronous and asynchronous functions.
@tdn.traced_run("CalendarAssistant")
def answer(question):
return call_model(question)
Framework integrations
The newer ones, briefly. Each records agents, model calls (with token usage and cost where the framework reports it) and tool calls, and marks the step where a failure happened.
Claude Agent SDK (pip install "agent-tracedown[claude-agent-sdk]"). Wrap the message stream; messages pass through unchanged. Subagents started with the Task tool nest under their own agent span, and the run's cost comes from ResultMessage.total_cost_usd.
from agent_tracedown.integrations import claude_agent as tdn_claude
async for msg in tdn_claude.trace_stream(query(prompt=p, options=opts), name="CodingAgent", prompt=p):
...
Google ADK (pip install "agent-tracedown[google-adk]"). Add the plugin to your app; it only observes.
from agent_tracedown.integrations import google_adk as tdn_adk
app = App(name="support", root_agent=root_agent, plugins=[tdn_adk.TracedownPlugin()])
runner = InMemoryRunner(app=app)
Pydantic AI (pip install "agent-tracedown[pydantic-ai]"). Run the agent through the wrapper; runs that raise are recorded too.
from agent_tracedown.integrations import pydantic_ai as tdn_pai
result = await tdn_pai.run(agent, "Refund order 42") # or tdn_pai.run_sync(...)
MCP (pip install "agent-tracedown[mcp]"). Instrument a mcp.Client or ClientSession; inside a run, every call_tool becomes a step and list_tools records the server's tools and their input schemas.
from agent_tracedown.integrations import mcp as tdn_mcp
tdn_mcp.instrument(client, server="billing") # or tdn_mcp.instrument_all()
with tdn.run("SupportAgent", input=question):
await client.list_tools()
await client.call_tool("refund", {"order_id": 42})
Documentation, benchmarks and the demo are in the repository. Licensed under Apache-2.0.
Metadata
Release files for agent-tracedown 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| agent_tracedown-0.3.0.tar.gz | 43.9 kB | With provenance | Details for agent_tracedown-0.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| agent_tracedown-0.3.0-py3-none-any.whl | Python 3 | none | any | Details for agent_tracedown-0.3.0-py3-none-any.whl |
Total release size: 93.5 kB
Release files / agent_tracedown-0.3.0.tar.gz
| Download URL | agent_tracedown-0.3.0.tar.gz |
|---|---|
| Size | 43.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f833951a2c34612d0ffcfdfebe8eb3876795f08e5f13831bb103b97ee5199c44
|
|
BLAKE2b-256 checksum How to use checksums |
631faa78e5d26a7cb269a11e191f8ac4aebe2b454da6884bcb4d72150272b6d5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.
Transparency logRelease files / agent_tracedown-0.3.0-py3-none-any.whl
| Download URL | agent_tracedown-0.3.0-py3-none-any.whl |
|---|---|
| Size | 49.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5e4ccd63ee24de0795a229c2a15768afdba1c54eb59a9cadf60c8e03ea2b9d3a
|
|
BLAKE2b-256 checksum How to use checksums |
6f240758df3eb1f762e4c3771dc1467b9cc30938b1e66ec1c9abdbb045b87501
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.
Transparency logSecurity for agent-tracedown 0.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for agent_tracedown-0.3.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.