Aggregator for halo2 plonk circuits, including:
- Provide aggregation circuit for target circuit verification.
- Provide solidity code for aggregation circuit verification.
- truffle
cargo test test_solidity_render --release -- --nocapture
In terminal 1:
cd sol
yarn
yarn start
In terminal 2:
cd sol
truffle test
cargo test test_solidity_render --release -- --nocapture
cd sol
yarn
# add INFURA_PROJECT_ID, MNEMONIC in .env file
# NOTICE!!! This command would spend about 0.025 GoerliETH for deployment
# This command is a liitle bit slow in my test env, please wait for several minutes
truffle test --goerli
The solidity code generation depends on the sol folder. You can download it from source code or release according to the version.
- call
run_circuit_unsafe_full_pass()for target circuit withTranscriptHash::Poseidonto get aggregation circuit and its instances. - call
run_circuit_unsafe_full_pass()for aggregation circuit withTranscriptHash::Shato create aggregation circuit proof. - call
solidity_render()withTranscriptHash::Shato generate solidity code. - call
solidity_aux_gen()to prepare aux input for solidity verify. It will prepare scalar division result used by the verification to reduce gas.
See test test_solidity_render for sample.