Skip to main content

Decision Trace Python SDK

The Python SDK provides the core tracing API, CLI, examples, and local collector workflow for Decision Trace.

Install

pip install decision-trace

Install the optional local collector dependencies if you want the bundled FastAPI collector and decision-trace dev workflow:

pip install "decision-trace[collector]"

Quickstart

from decision_trace import decision

with decision("loan.approval", actor={"type": "system", "id": "risk_engine"}) as d:
    d.evidence("credit_score", 720)
    d.policy_check("min_score_700", "pass")
    d.outcome("approved")

Local Collector

Start the local collector:

decision-trace dev

This binds a local-only example collector on 127.0.0.1:8711 and writes events to ./data/events.jsonl.

Development

pip install -e ".[collector,test]"
pytest

Docs And Examples

Metadata

Release files for decision-trace 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for decision-trace 0.1.1
File Size Uploaded Provenance Actions
decision_trace-0.1.1.tar.gz 25.0 kB With provenance Details for decision_trace-0.1.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for decision-trace 0.1.1
File Interpreter ABI Platform Actions
decision_trace-0.1.1-py3-none-any.whl Python 3 none any Details for decision_trace-0.1.1-py3-none-any.whl

Total release size: 55.7 kB

Release files / decision_trace-0.1.1.tar.gz

Download URL decision_trace-0.1.1.tar.gz
Size 25.0 kB
Tags Source
SHA-256 checksum
How to use checksums
4dbb8b0a6206ee508d7c3c514c6901f5992095552eb899fd74d7cccce5cbfcc2
BLAKE2b-256 checksum
How to use checksums
92213be3ccdd66f6ed04842a94fe6375be6768554f53514090e0b1967d516591
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

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 Apr 21, 2026.

Transparency log

Release files / decision_trace-0.1.1-py3-none-any.whl

Download URL decision_trace-0.1.1-py3-none-any.whl
Size 30.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3122f84c8aefe1160f9f72cfb9df8589d33580a72488e9683e4c4667cf179297
BLAKE2b-256 checksum
How to use checksums
31be0fee4f1f4ccbb8fb0e2437fb018ad68f39870366848fa6431c3172210cd3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

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 Apr 21, 2026.

Transparency log

Security for decision-trace 0.1.1

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

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for decision_trace-0.1.1.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 Apr 21, 2026.

Transparency log

A 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.

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page