Skip to content

Commit

Permalink
Add side-loaded keys support
Browse files Browse the repository at this point in the history
  • Loading branch information
mrmr1993 committed Dec 13, 2023
1 parent 90c714c commit d8ac33a
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/bindings
13 changes: 13 additions & 0 deletions src/snarky.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -859,6 +859,19 @@ declare const Pickles: {

proofToBase64Transaction: (proof: Pickles.Proof) => string;

sideLoaded: {
// Create a side-loaded key tag
create:(name: string, numProofsVerified: 0 | 1 | 2, publicInputLength: number, publicOutputLength: number) => unknown /* tag */,
// Instantiate the verification key inside the circuit (required).
inCircuit:(tag: unknown, verificationKey: string) => undefined,
// Instantiate the verification key in prover-only logic (also required).
inProver:(tag: unknown, verificationKey: string) => undefined,
// Create an in-circuit representation of a verification key
vkToCircuit:(verificationKey: unknown) => unknown /* verificationKeyInCircuit */,
// Get the digest of a verification key in the circuit
vkDigest:(verificationKeyInCircuit: unknown) => Field,
};

util: {
toMlString(s: string): MlString;
fromMlString(s: MlString): string;
Expand Down

0 comments on commit d8ac33a

Please sign in to comment.