Skip to main content
A counterfactual trace is a structured audit record created each time Wu-Weism evaluates a counterfactual query — “what would have happened to outcome had variable been set to value?” Traces capture the full provenance of that reasoning: the SCM used, the intervention applied, the adjustment set, the causal assumptions, and the AI provider that executed the analysis. Traces are immutable once created. You can retrieve them by traceId to inspect past reasoning, attach them to claims, or audit your causal workflow.

Get a counterfactual trace

This endpoint requires authentication. Include your session token in the Authorization header.

Path parameters

string
required
UUID of the counterfactual trace to retrieve. Trace IDs are returned when counterfactual analyses are run through the causal chat or hybrid synthesize pipelines.

Response fields

string
required
UUID of the trace. Matches the traceId supplied in the request path.
object
required
Reference to the SCM used for this counterfactual evaluation.
object
required
The causal intervention that was evaluated.
string
required
The outcome variable evaluated under the intervention.
string
required
The algorithmic method used to compute the counterfactual. Currently "deterministic_graph_diff" for all traces — this method computes the counterfactual by propagating the intervention through the SCM’s directed acyclic graph and diffing the resulting outcome distribution against the factual.
string[]
required
List of causal assumptions that were active during evaluation (e.g., "acyclicity", "no unmeasured confounding", "stable unit treatment value assumption").
string[]
required
Variables conditioned on to satisfy the identifiability criterion. Corresponds to the confirmed adjustment set from intervention validation.
object
required
Execution metadata for the trace.

Example

Traces are scoped to your account. You can only retrieve traces created within your own sessions. Attempting to access another user’s trace returns 404 Not Found.