proof-aggregation/codex-plonky2-circuits/README.md

30 lines
1.5 KiB
Markdown
Raw Permalink Normal View History

2024-10-07 08:36:11 +00:00
# Codex Plonky2 Circuits
WARNING: This is a work-in-progress prototype, and has not received careful code review. This implementation is NOT ready for production use.
This crate is an implementation of the [codex storage proofs circuits](https://github.com/codex-storage/codex-storage-proofs-circuits) for the plonky2 proof system.
2024-10-15 12:33:02 +00:00
## Code organization
- [`merkle_safe`](./src/merkle_tree/merkle_safe.rs) is the implementation of "safe" merkle tree used in codex, consistent with the one [here](https://github.com/codex-storage/nim-codex/blob/master/codex/merkletree/merkletree.nim).
2024-11-05 11:57:49 +00:00
- [`merkle_circuit`](./src/circuits/merkle_circuit) is the Plonky2 Circuit implementation of "safe" merkle tree above.
2024-10-15 12:33:02 +00:00
2024-10-18 10:45:31 +00:00
- [`sample_cells`](./src/circuits/sample_cells.rs) is the Plonky2 Circuit implementation for sampling cells in dataset merkle tree.
2024-11-14 09:31:32 +00:00
- [`keyed_compress`](./src/circuits/keyed_compress.rs) is the compression function used in the construction (and reconstruction) of the Merkle tree root. The function takes 2 hash digest (4 Goldilocks field elements each) and a key, then outputs a single hash digest.
- [`sponge`](./src/circuits/sponge.rs) contains the hash function (with and without padding) used to hash cells and during sampling.
2024-10-18 10:45:31 +00:00
- [`params`](./src/circuits/params.rs) is the parameters used in the circuits.
- [`utils`](./src/circuits/utils.rs) contains helper functions.
2024-11-14 09:31:32 +00:00
## Documentation
writeup coming soon...
2024-10-15 12:33:02 +00:00
## Usage
2024-11-14 09:31:32 +00:00
see [`workflow`](../workflow) for how to use the circuits and run them.
2024-10-15 12:33:02 +00:00
2024-10-07 08:36:11 +00:00
## Benchmarks
2024-11-14 11:26:37 +00:00
see [`BENCHMARKS.md`](../workflow/BENCHMARKS.md)