Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Agent Reliability

AI agents can finish successfully while still doing the wrong thing. Agent Reliability provides vendor-neutral Python primitives for measuring whether agents meet explicit reliability objectives.

It brings evaluations, SLOs, error budgets, burn rates, and measurement provenance to agent applications—and refuses to produce a misleading number when evaluation methodologies are incompatible.

Status: GA (1.2.1 is the latest published release; 1.3.0rc1 is an unpublished release candidate, see release notes). Public APIs documented as stable in GA_CONTRACT.md follow Semantic Versioning. See compatibility.

Why this exists

Traces explain what an agent did. Reliability answers whether it consistently achieved a defined outcome. Agent Reliability connects one logical execution to an explicit evaluation method, then calculates exact local reliability against an SLO.

The OSS package works offline and without a hosted service. It does not automatically capture prompts, responses, tool arguments, credentials, or arbitrary application payloads. The base install has no runtime dependencies and sends nothing over the network.

30-second example

python -m pip install agent-reliability

This standalone example instruments four agent-like calls, evaluates task_success, records attributable results, and applies a 75% SLO:

from fractions import Fraction

from agent_reliability.domain import ObjectiveDirection, Slo, UnknownPolicy
from agent_reliability.evaluation import (
    EqualityEvaluator,
    EvaluationResult,
    EvaluatorIdentity,
)
from agent_reliability.reliability import (
    AggregationConflict,
    ReliabilityObservation,
    evaluate_reliability,
)
from agent_reliability.sdk import AgentReliability, EvaluatorRunner

sdk = AgentReliability()
runner = EvaluatorRunner()
evaluator = EqualityEvaluator(EvaluatorIdentity("expected-answer", "1"), "approved")
observations = []

for actual in ("approved", "approved", "needs-review", "approved"):
    with sdk.run(agent_id="approval-agent", name="Approval Agent", version="1") as run:
        result = runner.evaluate(evaluator, actual)
        if not isinstance(result, EvaluationResult):
            raise RuntimeError("evaluation did not produce an observation")
        run.record_evaluation(indicator="task_success", result=result)
        observations.append(
            ReliabilityObservation.from_evaluation(
                indicator="task_success", result=result
            )
        )

report = evaluate_reliability(
    indicator="task_success",
    observations=observations,
    slo=Slo("task-success", Fraction(3, 4), ObjectiveDirection.AT_LEAST),
    unknown_policy=UnknownPolicy.EXCLUDE,
)
if isinstance(report, AggregationConflict):
    raise RuntimeError("incompatible measurement methodologies")

print(f"Reliability: {float(report.ratio.pass_ratio):.2%}")
print(f"SLO status: {report.slo_evaluation.status.value.upper()}")

Output:

Reliability: 75.00%
SLO status: MET

This block runs in CI. The canonical example also shows the error budget. Follow the 5–10 minute quickstart for interpretation and next steps.

What it measures

  • An indicator says what is measured, such as task_success.
  • An evaluator says how it is judged and returns PASS, FAIL, or UNKNOWN.
  • Provenance records evaluator name, behavior version, configuration, and determinism.
  • An SLI is the observed ratio; an SLO is the desired target.
  • The error budget is permitted unreliability; burn rate compares an observed bad-event rate with that allowance.

UNKNOWN means evaluation completed but was indeterminate. An EvaluationExecutionFailure means the evaluator or its timestamping failed; it is not an agent failure and creates no observation.

Reliability answers “how often is the agent behaving correctly?” Measurement health answers “do we have enough trustworthy evidence to make that claim?” They remain independent, and applications—not the SDK—decide how degraded evidence affects an action. See the measurement-health guide. Runnable fail-open, fail-closed, and bounded-degradation examples are in the application policy guide.

If evaluator v1 and v2 measured the same indicator, the engine returns an AggregationConflict instead of averaging them. A changed measurement method is not automatically comparable. See Core concepts.

Installation

Python 3.11–3.13 is supported. The distribution and import names differ:

pip install agent-reliability
import agent_reliability

The only optional runtime extra is the OpenTelemetry API bridge:

python -m pip install "agent-reliability[otel]"

Framework compatibility

Any Python agent can use the explicit sync or async context manager. Wrap one logical task execution, evaluate the relevant output, and retain observations for the window your application chooses. No framework adapter, monkey patch, API key, storage layer, or network service is required. See Integrations and the async example.

The local engine calculates one supplied collection at a time; it does not retain history or select rolling windows.

OpenTelemetry

OpenTelemetryRunContextBridge activates the agent span in an existing host trace. Your application owns the TracerProvider, sampling, processors, propagation, exporter, collector, and backend. Agent Reliability configures none of them and exports nothing by itself. See the OTel example and mapping reference.

Project status and scope

Agent Reliability is a stable, local-first Python SDK for measuring and testing the reliability of AI agents.

The SDK provides sync and async agent instrumentation, deterministic evaluators, evaluator provenance, reliability aggregation, SLO and error-budget semantics, measurement-health tracking, optional OpenTelemetry interoperability, human-readable local reports, machine-readable reliability results, and framework-neutral SLO assertions for tests and CI.

The SDK is designed to work standalone. It requires no hosted account, API key, or network service, and has zero mandatory runtime dependencies.

Current published release: 1.2.1 (release candidate 1.3.0rc1 prepared; not published)

The public API follows semantic versioning, with compatibility and installed-artifact verification included in the release process.

The published 1.2.1 package includes no remote ingestion, dashboard, LLM judge, persistence, auto-instrumentation, or framework-specific adapter. The 1.3 release candidate adds an optional HTTP evidence exporter (pip install 'agent-reliability[http]', see HTTP exporter) and an experimental LLM-judge adapter (described below); neither is in the published release. See the roadmap.

LLM-judge evaluators (experimental, unreleased)

agent_reliability.experimental.judge is an Experimental, unreleased adapter for model-backed evaluators that call a provider you supply. It adds no dependency and sends raw content only to your provider. The reference rubrics are uncalibrated examples. See Evaluate. A sync judge's timeout is best effort unless the provider is wrapped in ExecutorSyncProvider; the provider's own client timeout is the real bound (see the same page).

Documentation

Development and contributing

See CONTRIBUTING.md for setup and quality gates. Security vulnerabilities belong in the private process in SECURITY.md, not a public issue.

License

Apache License 2.0. See LICENSE.

HTTP evidence delivery

The optional HTTP exporter sends schema-v2 evidence using agent-reliability[http], bounded delivery queues and explicit shutdown. Platform integration and independent review remain required before release.

Metadata

Release files for agent-reliability 1.3.0rc1

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

Source distribution (sdist)

Source distribution for agent-reliability 1.3.0rc1
File Size Uploaded Provenance
agent_reliability-1.3.0rc1.tar.gz 459.1 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for agent-reliability 1.3.0rc1
File Interpreter ABI Platform
agent_reliability-1.3.0rc1-py3-none-any.whl Python 3 none any Details

Total release size: 603.7 kB

Release files / agent_reliability-1.3.0rc1.tar.gz

Download URL agent_reliability-1.3.0rc1.tar.gz
Size 459.1 kB
Tags Source
SHA-256 checksum
How to use checksums
1260fe1afc1ede98ba4f5ccd1f03de56665286d651d53c4697ee06406450763e
BLAKE2b-256 checksum
How to use checksums
195c445478699a9ca6cff293a01306cdaec56dbd388d54e6f56fadc603d2b032
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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

Transparency log

Release files / agent_reliability-1.3.0rc1-py3-none-any.whl

Download URL agent_reliability-1.3.0rc1-py3-none-any.whl
Size 144.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2df5bf88b841f2901d53a64ab4d13473daf5dce2453ce534c9338196547d0273
BLAKE2b-256 checksum
How to use checksums
528c25b68a7416c8ce715f21e8ee2793becb679c7f54dd1bfaf5d4a29b9c61ea
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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

Transparency log

Security for agent-reliability 1.3.0rc1

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.

Select from 2 files

Attestation for agent_reliability-1.3.0rc1.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 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.

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