Skip to main content

airbender_host/
lib.rs

1#![doc = include_str!("../README.md")]
2// TODO: This feature is not really required, but added as a workaround for:
3// https://github.com/rust-lang/rust/issues/141492
4// See also:
5// - https://github.com/rust-lang/rust/issues/144690
6// - https://github.com/rust-lang/rust/issues/133199
7#![cfg_attr(doc, feature(generic_const_exprs))]
8
9mod cycle_marker;
10mod error;
11mod inputs;
12mod program;
13mod proof;
14mod prover;
15mod receipt;
16mod runner;
17mod security;
18mod verifier;
19mod vk;
20
21pub use airbender_core::guest::Commit;
22pub use cycle_marker::{CycleMarker, Mark};
23pub use error::{HostError, Result};
24pub use inputs::Inputs;
25pub use program::Program;
26pub use proof::{DevProof, Proof, RealProof};
27pub use prover::{
28    CpuProver, CpuProverBuilder, DevProver, DevProverBuilder, ProveResult, Prover, ProverLevel,
29};
30#[cfg(feature = "gpu-prover")]
31pub use prover::{GpuProver, GpuProverBuilder};
32pub use receipt::Receipt;
33pub use runner::{
34    resolve_cycles, ExecutionResult, FlamegraphConfig, Runner, TranspilerRunner,
35    TranspilerRunnerBuilder, DEFAULT_CYCLES,
36};
37pub use security::SecurityLevel;
38pub use verifier::{
39    verify_real_proof_with_vk, DevVerificationKey, DevVerifier, DevVerifierBuilder,
40    RealUnifiedVerificationKey, RealUnrolledVerificationKey, RealVerifier, RealVerifierBuilder,
41    VerificationKey, VerificationRequest, Verifier,
42};
43pub use vk::{
44    compute_unified_vk, compute_unrolled_vk, verify_proof, verify_unrolled_proof, UnifiedVk,
45    UnrolledVk,
46};
47
48/// Raw Airbender re-exports without stability guarantees.
49///
50/// These items are not recommended for normal use. They are exposed for rare
51/// cases, for example when a project depends on both `airbender-host` and
52/// direct Airbender crates at the same time.
53pub mod raw {
54    pub use execution_utils::unrolled::UnrolledProgramProof;
55}