UNPKG

@nori-zk/proof-conversion

Version:

Verifying zkVM proofs inside o1js circuits, to generate Mina compatible proof

40 lines (39 loc) 1.19 kB
import { ComputationalStage, ComputationPlan } from '../../plan.js'; import { PlatformFeatures } from '../platform/index.js'; import { Risc0Proof, Risc0RawVk } from '../../../api/sp1/types.js'; export type Groth16Input = { risc0_proof: Risc0Proof; raw_vk: Risc0RawVk; }; export interface Groth16ProofData { maxProofsVerified: 0 | 1 | 2; proof: string; publicInput: string[]; publicOutput: string[]; } export interface Groth16VkData { data: string; hash: string; } export interface Groth16Output { vkData: Groth16VkData; proofData: Groth16ProofData; } interface State extends PlatformFeatures, Groth16Output { workingDirName: string; workingDir: string; cacheDir: string; input: Groth16Input; witnessPath: string; proofPath: string; vkPath: string; } export declare class Groth16ComputationalPlan implements ComputationPlan<State, Groth16Output, Groth16Input> { readonly __inputType: Groth16Input; name: string; init(state: State, input: Groth16Input): Promise<void>; stages: ComputationalStage<State>[]; then(state: State): Promise<Groth16Output>; finally(state: State): Promise<void>; } export {};