Ligero: https://github.com/arkworks-rs/poly-commit/tree/master/poly-commit/src/linear_codes
Ligero is built around the following key components:
- Prime field arithmetic (operations are performed over a prime field $\mathbb{F}_p$)
- One-sided RS encoding
- Merkle tree commitments over encoded rows
- Randomized checking through proximity and consistency tests
Required Changes for ZODA
Field Change
- Current: Ligero operates over a prime field $\mathbb{F}_p$.
- ZODA requirement: Operations should be over a binary field $\mathbb{F}_{2^k}$.
Two-Sided RS Encoding
- Current: Ligero uses one-sided RS encoding (applied across rows).
- ZODA requirement: Two-sided RS encoding (both across rows and columns) is needed.
Randomization Step (Diagonal Scaling)
- Current: Ligero does not randomize data between RS encodings.
- ZODA requirement:
- After row encoding to obtain $X$, we must randomly scale each column by a random field element.
- Construct a diagonal matrix $D_r$ where $D_r[i][i] = r_i$ is random (derived via Fiat–Shamir).
- Perform matrix multiplication $X \cdot D_r$ before column encoding.
Multiple Merkle Trees
- Current: Ligero commits to a single Merkle tree (over rows).
- ZODA requirement:
- Construct three separate Merkle trees:
- root_X: Commitment to the rows of $X.$
- root_Y: Commitment to the columns of $Y$ (after random scaling and RS encoding).
- root_Z: Commitment to the final matrix $Z$.
- Verifiers will sample and check consistency across all three trees.