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

feat: implement ark-snark SNARK trait #15

Open
4 tasks
Autoparallel opened this issue Dec 21, 2024 · 0 comments
Open
4 tasks

feat: implement ark-snark SNARK trait #15

Autoparallel opened this issue Dec 21, 2024 · 0 comments

Comments

@Autoparallel
Copy link

Proposal

To make Spartan compatible with other proving backends, it would be helpful to implement the ark-snark SNARK trait. This would, for example, allow for Spartan to be used alongside Sonobe as opposed to the other SNARKs to choose from. Current list of known implementations are:

  • groth16
  • marlin
  • gm17
  • gemini
  • ripp
    (see here).

Those at Sonobe are definitely interested.

Work to be done

A while back there was a fork of this repo made by the arkworks community: https://github.com/arkworks-rs/spartan

It rests a handful of commits ahead and behind this repository but does not actually implement the necessary trait. Most of the changes are to swap to an arkworks backend in some places.

My guess is that it is not of interest to have this specific crate gutted this far to do this, but perhaps, at least, there could be a feature flag for arkworks.

More comments

Based on discussion, it seems like swapping out bellpepper for arkworks fields and curves would be the goal here. Not sure if the constraint system would also have to change, but likely will.

Tasks

These tasks are preliminary thoughts and may need to change.

  • Use ark-ff in place of ff.
  • Use ark-ec for curves.
  • Use ark-relations in place of bellpepper / bellpepper-core
  • Use ark-snark to implement SNARK trait for Spartan variants.

Backlink

Original discussion happened here. May need more discussion before moving forward.


I can at least start trying to do drop in replacements of ark-* crates with draft PR and we can monitor along the way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant