36 const BF& batching_challenge_v,
37 const BF& accumulated_result)
40 const auto compute_four_limbs = [](
const BF& in) {
41 return std::array<FF, 4>{
FF(in.binary_basis_limbs[0].element),
42 FF(in.binary_basis_limbs[1].element),
43 FF(in.binary_basis_limbs[2].element),
44 FF(in.binary_basis_limbs[3].element) };
47 const auto compute_five_limbs = [](
const BF& in) {
49 FF(in.binary_basis_limbs[1].element),
50 FF(in.binary_basis_limbs[2].element),
51 FF(in.binary_basis_limbs[3].element),
52 FF(in.prime_basis_limb) };
57 BF batching_challenge_v_power = batching_challenge_v;
58 for (
size_t i = 0; i < 4; i++) {
60 batching_challenge_v_power = batching_challenge_v_power * batching_challenge_v;
68 limb.clear_round_provenance();
83 const BF& evaluation_input_x,
84 const BF& batching_challenge_v,
85 const BF& accumulated_result,
95 using ClaimBatch = ClaimBatcher::Batch;
96 using InterleavedBatch = ClaimBatcher::InterleavedBatch;
103 vinfo(
"Translator vk hash in recursive verifier: ",
vk_hash);
105 VerifierCommitments commitments{
key };
106 CommitmentLabels commitment_labels;
111 mark_witness_as_used(accumulated_result.prime_basis_limb);
116 commitments.gemini_masking_poly =
transcript->template receive_from_prover<Commitment>(
"Gemini:masking_poly_comm");
119 commitments.op = op_queue_wire_commitments[0];
120 commitments.x_lo_y_hi = op_queue_wire_commitments[1];
121 commitments.x_hi_z_1 = op_queue_wire_commitments[2];
122 commitments.y_lo_z_2 = op_queue_wire_commitments[3];
125 for (
auto [comm, label] :
zip_view(commitments.get_non_opqueue_wires_and_ordered_range_constraints(),
126 commitment_labels.get_non_opqueue_wires_and_ordered_range_constraints())) {
127 comm =
transcript->template receive_from_prover<Commitment>(label);
131 FF beta =
transcript->template get_challenge<FF>(
"beta");
132 FF gamma =
transcript->template get_challenge<FF>(
"gamma");
138 commitments.z_perm =
transcript->template receive_from_prover<Commitment>(commitment_labels.z_perm);
143 const FF alpha =
transcript->template get_challenge<FF>(
"Sumcheck:alpha");
148 for (
size_t idx = 0; idx < gate_challenges.size(); idx++) {
153 libra_commitments[0] =
transcript->template receive_from_prover<Commitment>(
"Libra:concatenation_commitment");
159 std::ranges::fill(padding_indicator_array, one);
161 auto sumcheck_output = sumcheck.verify(
relation_parameters, gate_challenges, padding_indicator_array);
163 libra_commitments[1] =
transcript->template receive_from_prover<Commitment>(
"Libra:grand_sum_commitment");
164 libra_commitments[2] =
transcript->template receive_from_prover<Commitment>(
"Libra:quotient_commitment");
167 bool consistency_checked =
true;
168 ClaimBatcher claim_batcher{
169 .unshifted = ClaimBatch{ commitments.get_unshifted_without_interleaved(),
170 sumcheck_output.claimed_evaluations.get_unshifted_without_interleaved() },
171 .shifted = ClaimBatch{ commitments.get_to_be_shifted(), sumcheck_output.claimed_evaluations.get_shifted() },
172 .interleaved = InterleavedBatch{ .commitments_groups = commitments.get_groups_to_be_interleaved(),
173 .evaluations = sumcheck_output.claimed_evaluations.get_interleaved() }
175 auto opening_claim = Shplemini::compute_batch_opening_claim(padding_indicator_array,
177 sumcheck_output.challenge,
182 &consistency_checked,
184 sumcheck_output.claimed_libra_evaluation);
188 return pairing_points;
PairingPoints verify_proof(const StdlibProof &proof, const BF &evaluation_input_x, const BF &batching_challenge_v, const BF &accumulated_result, const std::array< Commitment, TranslatorFlavor::NUM_OP_QUEUE_WIRES > &op_queue_wire_commitments)
Creates a circuit that executes the Translator verifier algorithm up to the final pairing check.