mod run_manifest

module run_manifest

Deterministic provenance records for engine-backed runs. Deterministic provenance records for reproducible engine-backed runs.

Enums

enum ManifestError

Manifest verification failure.

MissingArtifact(String)

No digest exists for the requested artifact.

DigestMismatch

The supplied bytes do not match the recorded digest.

name: String

Artifact whose bytes differ from the recorded digest.

Structs and Unions

struct ArtifactDigest

SHA-256 digest for an artifact.

name: String

Relative artifact name.

sha256: String

Lowercase hexadecimal SHA-256 digest.

bytes: usize

Artifact size in bytes.

Implementations

impl ArtifactDigest

Functions

fn of(bytes: &[u8]) -> Self

Hash an artifact with its stable name.

struct RunManifest

Minimal machine-readable provenance manifest.

manifest_version: u16

Stable manifest schema version.

run_id: String

Caller-provided run identity.

seed: u64

Random seed used by the search.

evaluation_budget: u64

Evaluation budget.

engine: EngineDescriptor

Objective engine compatibility descriptor.

artifacts: Vec<ArtifactDigest>

Content-addressed run artifacts sorted by name.

Implementations

impl RunManifest

Functions

fn add_artifact(&mut self, name: impl Into<String>, bytes: &[u8])

Add or replace an artifact digest.

fn new(run_id: impl Into<String>, seed: u64, evaluation_budget: u64) -> Self

Create a manifest with the current public schema version.

fn to_json(&self) -> Result<String, serde_json::Error>

Serialize the manifest deterministically as pretty JSON.

fn verify_artifact(&self, name: &str, bytes: &[u8]) -> Result<(), ManifestError>

Verify bytes against a recorded artifact digest.