Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement user-facing API for recursive proving of IVC #251

Open
str4d opened this issue Apr 16, 2021 · 3 comments
Open

Implement user-facing API for recursive proving of IVC #251

str4d opened this issue Apr 16, 2021 · 3 comments
Labels
A-recursion Area: Recursive proofs A-rust-api Area: Public crate API C-target Category: This is a high-level target that forms the root of a sub-graph in the DAG.

Comments

@str4d
Copy link
Contributor

str4d commented Apr 16, 2021

The user-facing layer is typed on a single application curve, and hides all of the underlying scaffolding (#247). In particular, the end user doesn't need to care about the existence of the other curve in the cycle, or any of the recursive-proof-checking components (both the other-curve circuit, and the component inserted into their application circuit).

@str4d str4d added A-recursion Area: Recursive proofs A-rust-api Area: Public crate API labels Jul 22, 2021
@str4d str4d changed the title Implement user-facing API for recursive proving Implement user-facing API for recursive proving of IVC Dec 22, 2021
@str4d
Copy link
Contributor Author

str4d commented Dec 22, 2021

@ebfull and I paired on figuring out the DAG. There are two main components to the user-facing API:

  • Circuits.
    • Forced to use a certain field.
    • Given opportunity to configure and synthesize as now.
    • Circuits need some way to expose public inputs. This differs from now (they need to go through PCD), so need some kind of payload structure.
    • They need a way to consume the public inputs of previous proofs (but privately).
    • They need to know "am I the base case?" (indicating whether the previous proofs are valid at all).
      • Perhaps this will also require circuits to specify what the "default public input payload" should be in this base case? (In case it helps the application circuit impl.)
  • The tree description of the circuits and how they relate to each other.
    • E.g. "these circuits are leaves, and we compose two together".

@nikkolasg
Copy link

nikkolasg commented Feb 7, 2022

Forced to use a certain field.

I can think of some situations where you would like to have constraints on one field acting as the "scalar field", for operations with scalars and constraints on the other field acting as the base field for operations with points on the subgroup of the curve which has the order of the former field, to do points operations efficiently. In that case, it seems having the ability to design constraints in both "sides" is actually useful. Do you think the API you are designing will allow for that ?

@str4d
Copy link
Contributor Author

str4d commented Feb 7, 2022

The high-level API being designed for this issue won't allow for that use case, because getting that cross-circuit interaction right is tricky and requires care, and is and not something we want every user to need to deal with. But you should be able to use the underlying scaffolding from #247 for this, since the recursive circuit itself will be doing precisely this kind of work. I suspect once we've built both the underlying scaffolding and the other-field-oblivious API, we'll be in a better position to figure out ways to make it easier to write user circuits that leverage the cycle (and will probably end up building that API as part of writing the recursion circuit itself). In any case, that API is out of scope for this issue; I've opened #494 for discussing it further.

@str4d str4d added this to the First user-facing recursion API milestone Sep 1, 2022
@str4d str4d added the C-target Category: This is a high-level target that forms the root of a sub-graph in the DAG. label Feb 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-recursion Area: Recursive proofs A-rust-api Area: Public crate API C-target Category: This is a high-level target that forms the root of a sub-graph in the DAG.
Projects
None yet
Development

No branches or pull requests

2 participants