ConeReplay
Pre-deploy regression testing for multi-agent AI. Record traces from your production agent app, propose a change (new prompt, new tool response, new model), and replay only the events causally affected — everything else is served byte-identically from the recording.
Patent pending (U.S. Provisional Application 64/043,722). Product site and
pilot details: https://conereplay.com. SemVer commitments live in
VERSIONING.md and the on-disk trace contract in docs/trace-format.md in
the source repository.
Install
pip install conereplay # core + CLI
pip install conereplay[server] # hosted trace-store server
pip install conereplay[langgraph] # LangGraph recording adapter
pip install conereplay[providers] # anthropic / openai oracle backends
pip install conereplay[dev] # dev tooling (pytest, ruff, mypy, pip-audit)
Requires Python 3.11+. Core has three runtime deps (networkx,
pydantic, pydantic-settings).
CLI quickstart
# Single-trace replay → Markdown report
conereplay replay \
--trace examples/trace.json \
--modify examples/modify.json \
--report report.md
# Corpus-mode regression harness → aggregate report (Markdown or HTML)
conereplay corpus \
--traces examples/traces \
--modify examples/corpus-modify.json \
--report corpus.html \
--format html
# Migration audit: re-run recorded traces on a new model, per-trace
# outcome diff + go/no-go (needs OPENAI_API_KEY or ANTHROPIC_API_KEY)
conereplay migrate \
--traces ./traces --provider openai --model gpt-4o-mini \
--compare judge --max-change-rate 0.05 --report migration.md
# Emit a Mermaid or Graphviz diagram of a trace's causal DAG
conereplay diagram \
--trace examples/trace.json \
--modify examples/modify.json \
--format mermaid --out cone.mmd
Run conereplay <command> --help for the full reference (also in docs/cli.md
in the source repository).
Library quickstart
from conereplay import (
load_trace, ModificationSpec, selective_replay, compute_divergence,
render_markdown_report,
)
trace = load_trace("trace.json")
mod = ModificationSpec(target_event_id="e3", substituted_output=b"POLICY: 5 days")
divergent = selective_replay(trace, mod)
report = compute_divergence(trace, divergent)
print(render_markdown_report(trace, divergent, mod, report))
Architecture
Four layers.
| Layer | Purpose | Modules |
|---|---|---|
| Core algorithms | Deterministic, pure-stdlib | core/clock.py, core/cone.py, core/replay.py, core/diff.py |
| SDK | Recording + provenance | sdk/recorder.py, sdk/provenance.py, sdk/langgraph.py |
| Presentation | Reports + diagrams | core/report.py, core/corpus_report.py, core/corpus_html.py, core/diagram.py |
| Server | Hosted trace store | server/app.py, server/models.py |
Supporting infrastructure:
config.py— validated runtime config (pydantic-settings,CONEREPLAY_*env)flags.py— feature flags (CONEREPLAY_FLAGS_*env)logging_setup.py— structured text/JSON loggingaudit.py— append-only JSONL audit trail for compliancecore/schemas.py— pydantic contract models for trace + modification JSON
Configuration
All configuration is env-driven with the CONEREPLAY_ prefix. Defaults
are safe for local use. Sample overrides:
export CONEREPLAY_LOG_LEVEL=debug
export CONEREPLAY_LOG_FORMAT=json
export CONEREPLAY_DATA_DIR=/var/lib/conereplay
export CONEREPLAY_AUDIT_LOG_PATH=/var/log/conereplay/audit.jsonl
export CONEREPLAY_ENABLE_AUDIT=true
export CONEREPLAY_SERVER_DATABASE_URL=postgresql://...
See conereplay/config.py for the full list.
Testing
make install-dev # install runtime + dev deps (pytest, ruff, mypy)
make test # run full pytest suite
make test-fast # fail-fast + failed-first
make test-cov # with coverage report (htmlcov/)
make lint # ruff
make typecheck # mypy
CI (.github/workflows/) runs tests + lint +
typecheck on every push and PR against main. Integration tests that
hit real LLM providers are gated behind CONEREPLAY_INTEGRATION=1.
Contributing
See CONTRIBUTING.md in the source repository.
Security
See SECURITY.md in the source repository for supply-chain posture and vulnerability
disclosure. Patent-pending proprietary code; see LICENSE in the source repository.
Runbooks
Operational procedures live in runbooks/ in the source repository:
deployment.md— releases + migrationson-call.md— incident triagedisaster-recovery.md— backups + restore
Documentation
In the source repository: docs/HANDOFF.md, docs/BACKLOG.md,
docs/LOCAL_DEVELOPMENT.md, docs/TESTING.md, docs/INFRASTRUCTURE.md,
docs/ROADMAP.md.
Evidence and sample
In the source repository:
- Sanitized end-to-end sample:
examples/sanitized_migration/README.md - Reproducible attribution configuration:
examples/sanitized_migration/bisect.json - Replay benchmark methodology:
docs/BENCHMARKS.md
The sample is synthetic and labels fixture measurements separately from live-provider evidence.
Release files for conereplay 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| conereplay-0.1.1.tar.gz | 106.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| conereplay-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 190.7 kB
Release files / conereplay-0.1.1.tar.gz
| Download URL | conereplay-0.1.1.tar.gz |
|---|---|
| Size | 106.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1d6d4f26cfc8cdad4906c03609e6a19358a5038b44b2f6896bfcf082e2244ea2
|
|
BLAKE2b-256 checksum How to use checksums |
b8b88d2832eed1e80579d4f2f58ae70cd6e7e56ccd032a2f58ecb238a8be01ac
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / conereplay-0.1.1-py3-none-any.whl
| Download URL | conereplay-0.1.1-py3-none-any.whl |
|---|---|
| Size | 84.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b998ccc8846cb91e4145be84f12f243f971838d884f8567a6a5baab5fd611672
|
|
BLAKE2b-256 checksum How to use checksums |
336db23c3d9d96a0d69931953d3932d914991dcf0930f3c4d7f95c653a4b3514
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|