Skip to main content Switch to mobile version tracekit-ai 1.4.0 Tamper-evident records of what AI agents did, and why: signed, policy-gated, verifiable offline
pip install tracekit-ai==1.4.0 Copy PIP instructions
Tracekit checks every tool call your agent makes before it runs, signs each call and decision into a hash chain, and gives you one .tkb file per run that anyone can verify offline.
Built like Certificate Transparency: signed records in an append-only log that independent witnesses cosign Open file format · verifiers in Python and TypeScript · MIT · runs on your own machines
Try it · Add it to your agent · What it proves · What's in it · Proof · How it works · Pilot it · Contribute · Docs
When an agent does something it shouldn't, you ask three things: what did it do, was it allowed, and can you trust the record? The agent's own log can't answer the third, because the agent can edit it. Here is one run, recorded both ways:
The same run, recorded: the database, the signer, the viewer and both edits are real; the model is scripted. Watch it with sound (1:47)
In this demo the signer ran as the agent's own user (dev mode), so an agent that knew how could have read the key and re-signed the log. Run the signer where the agent can't reach it, with a witness, and it can't.
uvx --from tracekit-ai tracekit demo --server No API key, and nothing to install with uv. From an empty cache on a Mac it took 5 seconds (10 with pip install tracekit-ai in a fresh venv). The package is tracekit-ai: tracekit on PyPI is an unrelated project. A scripted agent makes three calls, and you should see:
== agent run (SCRIPTED: fixed tool calls, not a model) Bash 'ls': allow Bash 'sudo rm -rf /': deny TK-D001 TK-D004 TK-F003 Bash 'echo "unterminated': ask TK-SHELL-PARSE ... Integrity: VERIFIED. == tamper test: rewrite the denied call as allowed in a copy, then verify again [FAIL] signatures — 11 record(s), keys valid at their position seq 4: hash does not match the event Integrity: FAILED. The delete was denied before it ran, the held call ran after an approval, and the run verified. Then the demo rewrote the denial as allowed in a copy, and verification failed at the record it changed.
pip install tracekit-ai import tracekit; tracekit.instrument() # the first line of your agent; then run it as usual tracekit last # Integrity: VERIFIED. / Assurance: dev; ... tracekit.instrument() starts a dev signer (or reuses the running one) and gates and records every tool and model call of the frameworks it finds. tracekit last exports your latest run, verifies it and says where it is. tracekit view --dev shows every run. On a clean machine the LangGraph example (a mock model, no API key) installed, ran and verified in 27 seconds: examples/v2/clean-machine.sh langchain.
Stable: Claude Code, the OpenAI Agents SDK, LangChain / LangGraph, the Claude Agent SDK and MCP. Experimental: Codex CLI, Cursor, Gemini CLI, CrewAI, Browser Use, Pydantic AI, Google ADK, Haystack, LlamaIndex, Microsoft Agent Framework, Strands Agents, the Vercel AI SDK, NVIDIA OpenShell, E2B, microsandbox, agentgateway, Wassette, LiteLLM's MCP gateway, Docker's MCP Gateway and the TypeScript SDK. In NVIDIA OpenShell sandboxes, Tracekit decides and signs each HTTP request OpenShell lets out, and signs OpenShell's own blocks, process events and policy changes into the same run. Setup: coding agents · OpenAI Agents SDK · Claude Agent SDK · LangChain / LangGraph · MCP · Wassette · CrewAI · Browser Use · Pydantic AI · Google ADK · Haystack · LlamaIndex · Microsoft Agent Framework · Strands Agents · NVIDIA OpenShell · LiteLLM · TypeScript · Vercel AI SDK · agentgateway · microsandbox · E2B · Docker MCP Gateway · OpenTelemetry · any other agent
Coding agents: tracekit init --dev --v2 wires Claude Code's hooks to a dev signer; add --agent codex, cursor or gemini for the others (experimental). With Claude Code's sandbox on, Tracekit holds each unsandboxed retry for a person (Claude Code's sandbox); with Codex's, see what Tracekit sees and the settings to use (Codex's sandbox); with Gemini CLI's tool sandbox, Tracekit holds each sandbox expansion for a person (Gemini CLI's sandbox). Running sandbox-runtime's proxy on its own, Tracekit decides each request it forwards (experimental, sandbox-runtime). Sandboxed with agentsh? tracekit follow signs each decision agentsh logs, as it writes it (experimental, agentsh). Without uv: pip install tracekit-ai, then tracekit demo --server. --why (experimental) shows a held email whose cause is found by replay and cited by its signed record:
tracekit demo --server # exit 0 tracekit demo --why # exit 0 tracekit init --dev --v2 From a checkout, the shipped sample bundles (v1) check with the verifier alone (pip install --no-deps tracekit-ai is enough), and python examples/v2/langchain/agent.py --scripted runs a LangGraph agent with a mock model:
tracekit verify docs/sample/demo-run.tkb --key docs/sample/signer.pub # exit 0 tracekit verify docs/sample/demo-run-tampered.tkb --key docs/sample/signer.pub # exit 1 TypeScript needs Node 18 or newer: npm install @cygnuxlabs/tracekit, and npx @cygnuxlabs/tracekit up starts a dev signer without Python on Apple Silicon Macs, Linux and Windows (TypeScript SDK). Python 3.9 to 3.13; the framework integrations need 3.10 or newer.
Three guarantees. They're related, but one doesn't give you the others, and each needs something different.
Dev mode protects nothing against an agent that runs as you. Dev runs say isolation: same-user (FAQ).
A verified run proves the record is intact: not intent, not that a reported tool result is true, and not that every action was captured (FAQ). tracekit analyze --v2 compares what was asked, what the model said and what ran, but what the model said is its own account, and findings are an opinion beside the integrity, never part of it (findings).
Actions outside the capture path leave no record, such as a subprocess a hook never sees and no kernel sensor import covers, or code that skips the adapter (adapters).
Policy rules match text and tool names. A determined agent can reword a command; the protection is the signer's isolation (policy reference).
Commitments hide content, not timing, sizes or counts (privacy).
What each deployment guarantees, from dev mode to a signer the agent can't reach: guarantees. Every limit, with what to do about it: limits. How it maps to the EU AI Act, ISO/IEC 42001, the NIST AI RMF and OWASP: compliance.
One signer. The core is stable and is hardened first. The rest ships in the same package as experimental: it works and is tested, but may change between releases (what's stable).
Our own experiments: small, synthetic and written by us. Nothing rounded up. The misses stay in.
Experiment Setup Result E1 tamper detection 120-record signed logs, 8 attacks, 60 trials each, re-run on 1.2 6 of 8 caught by the log alone, 8 of 8 with a witness E8 insider attacks Real unprivileged users against a Linux system-mode signer: a decoy signer, a stopped signer, a swapped policy, fabricated runs 8 of 8 caught, a merge gate on every pull request E17 policy packs 570 harmful and 738 benign tool calls in 11 classes, decided by both regex engines 570 of 570 stopped; 1 false alarm, a draft email held for a person E21 policy robustness 420 harmful and 432 benign calls written blind to the rules; 130 developer-session calls server pack: 211 of 420 stopped or held on the one blind run, 237 after rules were added that target the pool (read since); 18 of 432 false alarms, 2 of 130 in sessions; p99 150 µs E10 reconciliation 30 runs, 12 with a seeded discrepancy: a missing hook, a fabricated call, changed arguments 12 of 12 flagged, 0 false positives E9 overhead Signer round trip over a Unix socket, file storage, macOS quick run 0.45 ms p50, 0.91 ms p99 per call; 5,356 events/s E3 the v1 regex gate, on a rougher set 16 harmful and 20 benign calls written after the rules 11 of 16 caught, 1 false alarm. Rules are tripwires, not a sandbox The two E1 misses are the design: a log can't see its own tail cut off, and whoever holds the key can re-sign it. Only a copy of the head held elsewhere, a witness, catches those, so an unwitnessed run verifies as dev. The test sets were written by us, and no one outside has reviewed the threat models yet. Every experiment, and what isn't measured: evaluation · technical report.
The agent never holds a signing key and never assigns sequence numbers.
Each record is signed and carries the hash of the one before it, so a changed byte fails verification at that record.
Nothing the agent reports about itself is trusted: not its isolation, its fail mode, gaps, or who approved a call.
Who can rewrite the log decides what a run is worth, so put the signer where the agent can't reach it. The agent's code is the same in every mode; TRACEKIT_SIGNER points it at the signer.
The operator who runs the signer could still rewrite its log with its own key; an independent witness and a monitor make that visible. Each mode end to end: deployment. The full model: architecture, laptop and server threat models.
For debugging a prototype, a tracer such as OpenTelemetry, Langfuse or LangSmith is the right tool. Tracekit doesn't replace one; it's the record you can hand to someone who doesn't trust the agent. How it compares with tracers, guardrail libraries and other tamper-evident logs, and when it's the wrong choice: comparisons.
Running an agent that acts on real systems, with someone who has to sign off on it: a customer, an auditor, an insurer? We'll set up Tracekit with you for two weeks, free: one agent, on your machines. At the end you have a verified evidence file for every run and a written review of what the agent did that you didn't expect. Email info@cygnuxlabs.com or open a pilot request.
tracekit demo --server # allow, deny, approve, then a tampered copy fails verification tracekit up # start the dev signer, or find the running one tracekit last # export your latest run, pin the dev key, verify it tracekit view --dev # every run, verified: calls, decisions, gaps, replay, why tracekit approvals list # calls held for a person; tracekit approvals approve ID tracekit export --v2 --run ID -o run.tkb # one run as one .tkb file tracekit verify run.tkb --trust trust.json # offline, against the keys you pinned in trust.json # (tracekit signer trust -o trust.json, or the one tracekit last wrote) tracekit policy lint policy.yaml # check a policy before the signer loads it tracekit doctor # check this setup tracekit init --dev --v2 # wire Claude Code's hooks; add --agent codex, cursor or gemini Nothing to install for whoever checks a run: the browser verifier, one page, takes the .tkb and its trust file, sends nothing anywhere, and says VERIFIED, FAILED or UNVERIFIABLE with what it means and what to do next.
Specified. Evidence format v2 aims to be precise enough to write an independent verifier, with normative test vectors.
Built on standards. Records are signed with Ed25519 over RFC 8785 canonical JSON. Each log is an RFC 6962 Merkle tree, the structure Certificate Transparency uses. Checkpoints are C2SP signed notes, and witnesses cosign them per C2SP tlog-cosignature.
Self-contained. A .tkb file is a zip of records, inclusion proofs, checkpoints and the policy snapshots that decided the calls. It holds no verification code.
Old files keep verifying. Formats only grow, each format's verifier is frozen, and an older verifier reports a newer file UNVERIFIABLE (needs tracekit >= x), never FAILED. Verify such a file with uvx --from "tracekit-ai>=x" tracekit verify run.tkb --trust trust.json, npx -y @cygnuxlabs/tracekit@latest verify run.tkb --trust trust.json (Node 20.12 or newer), or the browser verifier, which checks it in your browser and sends nothing. From 1.4.0, an addition an older verifier can leave unread is non-critical: the bundle verifies, and the report names what that verifier didn't interpret.
Verify a v1 bundle in GitHub Actions with uses: Cygnux-Labs/Tracekit@main (bundle: and key: or witness:). require-anchor defaults to true, so an unanchored bundle fails the step; set require-anchor: "false" to only report it.
Each of these is useful on its own, and none needs to know the whole codebase:
Write a verifier in another language. The evidence format is specified and has test vectors. A Go or Rust verifier written from the spec alone is the best test that the spec is complete.
Find a harmful call the packs let through. Add it to tests/data/policy/deny/ with a rule that catches it; E17 runs every case.
Run Tracekit on your own agent and report what broke. Doing that with two open-source agents found real bugs (case study).
Add a framework. An integration is done when it passes the adapter contract.
Try to break it. Find a tamper or a bypass that E1 and E8 miss, and report it privately as SECURITY.md describes. Everyone who finds one is named in the hall of fame unless they ask us not to.
To start: make install, then make check (contributing). Smaller tasks are labelled good first issue. Everyone taking part follows the code of conduct.
@software{tracekit2026, author = {{Cygnux Labs}}, title = {Tracekit: the tamper-evident flight recorder for AI agents}, year = {2026}, url = {https://github.com/Cygnux-Labs/Tracekit} } Agents can edit logs. They can't hide the edit. A star costs nothing and helps other teams find Tracekit.
Both files in this release have provenance metadata.
MIT View SPDX License List
yaml langchain grpc postgres aws why-anthropic signer dev
ai-agents observability audit audit-log tamper-evident claude-code security provenance opentelemetry agent-security guardrails mcp langchain langgraph openai-agents llm
Development Status 4 - Beta
Intended Audience Developers
Operating System OS Independent
Programming Language Python :: 3
Software Development :: Quality Assurance
Release files for tracekit-ai 1.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
Built distribution (wheel)
Total release size: 8.1 MB
Release files / tracekit_ai-1.4.0.tar.gz
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 verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 20, 2026.
Release files / tracekit_ai-1.4.0-py3-none-any.whl
Security for tracekit-ai 1.4.0
Both files in this release have been uploaded with provenance metadata.
With provenance tracekit_ai-1.4.0.tar.gz Oct 20, 2026
With provenance tracekit_ai-1.4.0-py3-none-any.whl Oct 20, 2026
Attestation for tracekit_ai-1.4.0.tar.gz
Attestation for tracekit_ai-1.4.0-py3-none-any.whl
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
Dec 3, 2026 2 release files Full provenance
Nov 28, 2026 2 release files Full provenance
Nov 27, 2026 2 release files Full provenance
Nov 24, 2026 2 release files Full provenance
Nov 18, 2026 2 release files Full provenance
Nov 9, 2026 2 release files Full provenance
Nov 3, 2026 2 release files Full provenance
Oct 31, 2026 2 release files Full provenance
Oct 30, 2026 2 release files Full provenance
Oct 28, 2026 2 release files Full provenance
Oct 24, 2026 2 release files Full provenance
Oct 20, 2026 2 release files Full provenance
Oct 18, 2026 2 release files Full provenance
Oct 16, 2026 2 release files Full provenance
Oct 13, 2026 2 release files Full provenance
Oct 11, 2026 2 release files Full provenance
Oct 10, 2026 2 release files Full provenance
Oct 9, 2026 2 release files Full provenance
"PyPI", "Python Package Index", and the blocks logos are registered trademarks of the Python Software Foundation.
© 2026 Python Software Foundation




