Skip to main content

Core schemas and utilities for Substr8 RunProof system

Project description

substr8-core

Core schemas and utilities for the Substr8 RunProof system.

Installation

pip install substr8-core

Usage

RunProof Schema

from substr8_core.schemas import RunProof, RunProofHeader, TraceEntry

# Create a RunProof
proof = RunProof(
    schema_version="runproof/v2",
    header=RunProofHeader(
        proof_id="proof_abc123",
        run_id="run_xyz789",
        agent_id="claims/orchestrator",
        runtime="langgraph",
        started_at="2026-03-09T10:00:00Z",
        status="completed"
    ),
    # ... rest of proof
)

# Serialize
proof_json = proof.model_dump_json()

# Validate
proof = RunProof.model_validate_json(proof_json)

RunState Schema

from substr8_core.schemas import RunState, LifecycleStatus

# Create run state
state = RunState(
    run_id="run_xyz789",
    agent_id="claims/orchestrator",
    lifecycle_status=LifecycleStatus.RUNNING,
    current_node="validate_output",
    step_index=5
)

# Update state
state.lifecycle_status = LifecycleStatus.COMPLETED

Verification

from substr8_core.crypto import verify_proof

result = verify_proof(proof)
print(result.valid)  # True/False
print(result.checks)  # Detailed check results

Schema Version

This package implements RunProof schema version runproof/v2.

License

MIT © 2026 Substr8 Labs

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

substr8_core-0.3.0.tar.gz (13.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

substr8_core-0.3.0-py3-none-any.whl (14.7 kB view details)

Uploaded Python 3

File details

Details for the file substr8_core-0.3.0.tar.gz.

File metadata

  • Download URL: substr8_core-0.3.0.tar.gz
  • Upload date:
  • Size: 13.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for substr8_core-0.3.0.tar.gz
Algorithm Hash digest
SHA256 f4126d0cb5d8a0bc27c753fdcbf2575bd68cd54dc049890627f7d1b3160d95bd
MD5 f92e602c3488061968a17825a2e8e9af
BLAKE2b-256 aa8bc01ea719a8208bd2c25a7febfb7946e2f930d45ca821fd404120d1bfebef

See more details on using hashes here.

File details

Details for the file substr8_core-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: substr8_core-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 14.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for substr8_core-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 81fc84b32ea6e0ef2f82cfcd8ac7a33f4fdbca1c372c0ef763dc3c61ed7e1b66
MD5 4e9505788c724a0eb3e9c47a3c53ff51
BLAKE2b-256 2fa167ff980e96fa17e15656deb39620086e23a6e77643869c1f3d13eb4cf016

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page