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

Mega PR: First iteration of prover and verifier #13

Merged
merged 198 commits into from
Jan 2, 2025
Merged

Mega PR: First iteration of prover and verifier #13

merged 198 commits into from
Jan 2, 2025

Conversation

luckyyang
Copy link
Collaborator

@luckyyang luckyyang commented Dec 16, 2024

Implemented a rough prover and verifier, includes:

  • algebra implementation of Zq, Rq and matrix
  • all prover's core computation
  • all verifier's core computation

Next stage work:

  • choosing proper parameters(now just use fix numbers)
  • add recursion

@Junochiu Junochiu changed the title Prover Mega PR: First iteration of prover and verifier Dec 28, 2024
refactor: verifier and prover reorg
Copy link
Collaborator

@Junochiu Junochiu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

perhaps no need to address the comments, we could discuss and if the issue make sense we create issues to fix after the pr is merged

Copy link
Collaborator

@Junochiu Junochiu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the work 🙏, will approve the pr 🙏 we could still check the discussion here and continue the fix with issues after merging.

@FoodChain1028
Copy link
Collaborator

My advice in algebra :)

(1) The coefficient of $R_q$/ PolynomialRing should be a fixed number.

https://github.com/zhenfeizhang/larkworks/blob/10273d10c5dc5efdeb777edaa27bcbeeb57a17b6/algebra/src/polynomial/zz_px.rs#L25-L31C2

impl<C: ConfigZZpX> Default for ZZpX<C> {
    fn default() -> Self {
        Self {
            coeffs: vec![ZZp::<C::BaseConfig>::default(); C::DIM],
        }
    }
}

(2) should check overflow in $Z_q$
(3) We can use a better way to init a PolynomialRing, since we don't want the user can only use just one kind of modulus Q and polynomial (i.e., $X^{64}+1$).
(4) some of the functions in utils.rs can be turned into the arithmetical operations in PolynomialRing

example:

impl Add for PolynomialRing{...}

@Junochiu
Copy link
Collaborator

Junochiu commented Jan 2, 2025

linked the unresolved comments to the issues, we'll merge this pr and continue the fixes from there 🚀

@Junochiu Junochiu merged commit 7fdfff9 into main Jan 2, 2025
3 checks passed
@SuccinctPaul SuccinctPaul deleted the prover branch January 2, 2025 03:09
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

Successfully merging this pull request may close these issues.

5 participants