Get example corpus provenance
get_corpus_provenanceCheck a sample file's trustworthiness by retrieving its provenance sidecar, including sources, evidence confidence, validation results, and SHA-256 hash.
Instructions
Return the provenance sidecar of one example file.
Use this to know how far to trust a file: the sources it was derived
from, the confidence of the evidence (``verified``, ``derived`` or
``assumed``), the validation ladder result per rung, what the builder
renamed or dropped to fit the edition, and the file's SHA-256.
Delegates to :func:`pain001.corpus.provenance`.
Args:
scenario_id: The scenario.
version: The message type.
variant: The overlay id of a bank variant, else ``None``.
Returns:
The parsed sidecar as a dict, or ``{"error": ...}`` when there is
no such file or no corpus.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| variant | No | An overlay id for the bank variant; omit for the generic file. | |
| version | Yes | The message type, e.g. 'pain.001.001.09'. | |
| scenario_id | Yes | The market scenario (from list_corpus_files). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| build | No | ||
| error | No | ||
| twins | No | ||
| family | No | ||
| sha256 | No | ||
| country | No | ||
| variant | No | ||
| scenario | No | ||
| provenance | No | ||
| validation | No | ||
| constraints | No | ||
| description | No | ||
| message_type | No |