DProvenanceKit turns every AI run into a queryable, diffable trace of its reasoning — then signs it with CryptoKit into a tamper-evident attestation you can verify offline. When an OS or model update makes your on-device agent silently drop a tool call or skip a step, it catches the regression and fails your build — before your users hit it.
A weather agent, traced through the Foundation Models adapter. Before an OS update it called getWeather for live conditions. After the update, the same prompt was answered straight from the model's prior — fluent, plausible, and wrong. Every traditional test stays green. Press run.
This is a scripted recording of real output. Open the live Explorer → to poke at the bundled sample diff in your browser, or drop in your own swift run DProvenanceKitCLI web-export JSON.
Traditional software crashes. AI usually doesn't — it fails quietly, and your logs show what happened, not why.
An agent silently stops calling a tool after a model update and answers from memory instead of live data.
Reasoning steps reorder between runs; a validation that used to gate a decision now runs after it.
Two supposedly identical runs take different routes and produce different results — with no obvious cause.
Latency, spans, service health, infrastructure. Answers what happened.
Decision lineage, logic diffs, regression detection. Answers why the AI reached this conclusion.
And when you need both, DProvenanceOTel exports finished runs as standard OTLP spans to Langfuse or any collector — DPK stays the on-device capture layer. Export, not equivalence.
1. Add the package (Swift Package Manager):
// Package.swift .package(url: "https://github.com/Therealdk8890/DProvenanceKit", from: "0.8.1")
2. Trace an Apple Foundation Models session — one line:
import FoundationModels import DProvenanceFoundationModels try await FMTrace.run(contextID: "chat", store: store) { let s = LanguageModelSession.traced(instructions: "Be terse.") _ = try await s.respond(to: "Plan my day.") }
Already have working FoundationModels code? session.recordProvenance() ingests the transcript after the fact — zero refactor. Every prompt, response, tool call, and generation error becomes a queryable trace event you can diff, align, and gate in CI.
Agents, LLM workflows, tool-using models, and reasoning that runs on-device with Apple Foundation Models, MLX, or Core ML. The observability ecosystem — LangSmith, Langfuse, Phoenix, OTel — is Python- and JS-first, built around requests crossing a network. DProvenanceKit works at the reasoning layer, in your language, with nothing leaving the device.
Pure Swift package. System SQLite + CryptoKit. Runs in your process; traces never leave the machine unless you export them.
The regression gate exits non-zero when a critical reasoning step disappears — the same way a failing test breaks your PR.
Not writing Swift? DProvenanceKitPython mirrors the API, with a drop-in CI action.
Everything in the public library — capture, query, diff, lineage, local signed attestation, offline proof packs, the FoundationModels adapter, and OTLP export — is Apache 2.0. The live paid offer is a defined 30-day assurance pilot, with other maintainer help scoped per engagement. There's no hosted service, recurring support tier, SLA, indemnity, or compliance-certification package.
The free web Explorer shares or previews one frozen before/after diff in the browser. D.P.K: Reasoning Traces is the native workbench over your live, local trace database — diff runs you choose, replay timelines, drill into payloads and span lineage, and surface anomalies across loaded runs. Basic is currently free. As of July 2026, an optional $99/year Pro Annual subscription is planned but not publicly purchasable; metadata, the D.P.K 1.3.0 submission, and Apple review still remain. Check the App Store for current availability.
Get the Mac app →Need an invoice or a different scoped engagement? therealdk8890+lineage@gmail.com · Full offer details in COMMERCIAL.md
Start free in five minutes — capture, diff, and gate PRs on reasoning drift in the open-source library. When one workflow needs hands-on integration and an assurance report, start the 30-day pilot.