KyroDB docs
Proof and replay
Trace diagnosis, feedback, proof bundles, replay, and shadow adoption for context reliability.
KyroDB evidence workflows exist so a developer can answer:
Why was this answer fresh, stale-blocked, degraded, irrelevant, or wrong-scope?
Trace-first debugging
Every retrieve response includes a trace_id.
In the console, start from Trace Lookup. The Runtime page smoke test prints a Trace Lookup URL after the first backend retrieve, so first-run debugging should not require manually searching for ids.
Use it immediately:
const trace = await client.observability.getTrace(packet.trace_id);
const diagnosis = await client.observability.diagnoseTrace(packet.trace_id);Trace and diagnosis help separate:
- stale source data;
- missed invalidation;
- backend unavailable;
- strict freshness blocked;
- cache reuse hit;
- fresh but irrelevant context;
- wrong-scope feedback.
Feedback
Record feedback when the served context was useful, stale, irrelevant, or wrong-scope.
await client.recordFeedback({
trace_id: packet.trace_id,
signal: "stale",
comment: "The answer used the old refund policy."
});Feedback becomes evidence for root-cause reports and proof workflows. Treat it as operational correctness signal.
Proof bundles
Proof bundles are redacted artifacts for adoption reviews and incident analysis.
In the console, Proof Center checks recent proof counters first, then generates a redacted proof bundle when you need a review artifact.
const bundle = await client.admin.buildProofBundle({ recent: 100 });A proof bundle should answer:
- what traffic was evaluated;
- what stale incidents were prevented;
- what degraded behavior remains;
- which evidence was redacted;
- whether proof quality is strong enough for cutover.
Share redacted proof bundles or root-cause reports for customer and partner review; keep full replay captures inside trusted operational workflows.
Replay and shadow
Replay is the adoption gate. Capture traffic, replay it, compare baseline and candidate behavior, then cut over only if safety gates pass.
In the console, Replay exports retained capture first. Advanced replay comparison workflows should use artifacts generated from the same project, not hand-written synthetic reports.
const capture = await client.admin.exportReplayCapture({ recent: 100 });
const shadow = await client.admin.createShadowSession({
schema_version: 1,
replay_primer: capture.replay_primer
});Cutover should fail on:
- strict freshness regressions;
- scope incidents;
- artifact alignment failures;
- candidate serving stale context where baseline blocked;
- proof-validation warnings that weaken the freshness claim.
Latency jitter should not be treated as semantic replay difference.