> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tenetlabs.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Verdict Traces

> Every decision returns a verdict and a decision_id correlation key, with a matching record on Tenet's side. Log both — your log is the audit trail.

**A verdict trace**: one decision → the verdict payload in your response + a server-side trace record keyed by a single correlation ID. The response is what your harness acts on — and what you log.

Your half of the audit trail is your own logs: log the correlation fields below on every call. To locate a decision on Tenet's side, quote its `decision_id` to Tenet support.

## The artifact set

| Artifact | Where it lives | What it answers |
| - | - | - |
| `findings[*].rule_ids` + `risk_labels` + `evidence_span` | Every response | The decision basis — what triggered each domain's verdict |
| `severity` + `verdict` | Every response | How serious, what was decided |
| Server-side record | Tenet's server-side decision trace, keyed by `decision_id` | What Tenet support looks up when you report a decision |
| `decision_id` / `canonical_id` | `decision_id` on every `/decide` response body (`CloudJudgeResponse.decision_id`); `canonical_id` on the stream (`request_accepted` event, and the `X-Tenet-Canonical-Id` header) | The correlation key — one 32-hex ID for this exact decision. Same value under both names |
| `session_id` | You supply it | Conversation grouping — every decision in one conversation lands in one trace |
| `workflow` | You supply it (optional) | Integration grouping — tags each decision with which of your integrations made the call, so one tenant's decisions filter per workflow. Trace-only; never affects the verdict |
| Policy version (`config_version`) | `GET /v1/config`, stamped on every trace | The exact policy bundle — a content hash — that made the decision |

## The correlation key

Tenet mints one 32-hex key for every decision — `decision_id` on the sync body, `canonical_id` on the stream. When a user reports a wrong block, quote that key to Tenet support to locate the decision.

The sync `/decide` body returns the key as `decision_id`; the stream returns it as `canonical_id`. `tenet-client` fills `CloudJudgeResponse.decision_id` on every path, sync and streaming — log that. Conversational harnesses should send `session_id` regardless — it's what groups a multi-turn interaction into one reviewable trace.

## Versioned decisions

Every trace records the `config_version` that decided it — a content hash of the compiled policy bundle, not a label. Two consequences an auditor will care about:

* **Reproducibility** — a verdict is attributable to the policy version in force at decision time.
* **Change attribution** — when behavior shifts, comparing `config_version` before and after tells you whether the policy moved or the traffic did.

`GET /v1/config` returns the live `config_version` for the environment you're hitting — the first check when a decision surprises you.

## What this means for compliance

The trace set maps onto what an examiner asks for, artifact by artifact:

| Examiner asks | Trace answers |
| - | - |
| "Why was this action blocked?" | The per-domain finding's `rule_ids` + `evidence_span` on the response |
| "Why was this action *allowed*?" | Each domain's `verdict` and `severity` in `findings[]` on the response |
| "Under which policy?" | `config_version` — the content-addressed bundle in force at decision time |
| "Show me the whole interaction" | `session_id` — the conversation-level trace |
| "Was a human involved?" | The `review` verdict is on the response. Tenet's trace holds the verdict, not the reviewer's decision — record that in your own logs next to `decision_id`. See [Human-in-the-loop](https://docs.tenetlabs.com/guides/hitl.md) |

## What your harness should log

Three fields turn your application logs into the other half of the audit trail:

```python theme={null}
log.info("judge_decision",
    decision_id=verdict.decision_id,                   # every path, sync and streaming
    session_id=session_id,                             # the same value you sent
    verdict=verdict.verdict,                           # merged top-level
    rule_ids=[r for f in verdict.findings for r in f.rule_ids],  # joins to the full chain
)
```

Never log `TENET_API_KEY` or `TENET_CLIENT_SECRET`, and treat `evidence_span` with the same care as the underlying content (it's a verbatim quote of it — except for PII findings, where it's a masked preview).

## Links

* [How the Judge decides — per-domain rule IDs and evidence](https://docs.tenetlabs.com/concepts/decisions.md)
* [Streaming — where `canonical_id` arrives](https://docs.tenetlabs.com/guides/streaming)
* [Human-in-the-loop — review records](https://docs.tenetlabs.com/guides/hitl.md)
* [What is Tenet — the compliance case](https://docs.tenetlabs.com/what-is-tenet.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.