diff --git a/bberg/src/circuit_builder.rs b/bberg/src/circuit_builder.rs index a7f393c3dd..a307a5746a 100644 --- a/bberg/src/circuit_builder.rs +++ b/bberg/src/circuit_builder.rs @@ -41,7 +41,7 @@ fn get_params() -> &'static str { r#" const FF gamma = FF::random_element(); const FF beta = FF::random_element(); - proof_system::RelationParameters params{ + bb::RelationParameters params{ .eta = 0, .beta = beta, .gamma = gamma, @@ -117,15 +117,15 @@ impl CircuitBuilder for BBFiles { let circuit_hpp = format!(" {includes} -using namespace barretenberg; +using namespace bb; -namespace proof_system {{ +namespace bb {{ {row_with_all_included}; class {name}CircuitBuilder {{ public: - using Flavor = proof_system::honk::flavor::{name}Flavor; + using Flavor = bb::honk::flavor::{name}Flavor; using FF = Flavor::FF; using Row = {name}FullRow; @@ -204,7 +204,7 @@ fn get_lookup_check_closure() -> String { const auto evaluate_logderivative = [&](const std::string& lookup_name) { // Check the logderivative relation - proof_system::honk::logderivative_library::compute_logderivative_inverse< + bb::honk::logderivative_library::compute_logderivative_inverse< Flavor, LogDerivativeSettings>( polys, params, num_rows); diff --git a/bberg/src/composer_builder.rs b/bberg/src/composer_builder.rs index b9be678677..2cad55278f 100644 --- a/bberg/src/composer_builder.rs +++ b/bberg/src/composer_builder.rs @@ -14,7 +14,7 @@ impl ComposerBuilder for BBFiles { " {include_str} -namespace proof_system::honk {{ +namespace bb::honk {{ using Flavor = honk::flavor::{name}Flavor; void {name}Composer::compute_witness(CircuitConstructor& circuit) @@ -109,7 +109,7 @@ std::shared_ptr {name}Composer::compute_verification_ke " {include_str} -namespace proof_system::honk {{ +namespace bb::honk {{ class {name}Composer {{ public: using Flavor = honk::flavor::{name}Flavor; @@ -129,7 +129,7 @@ class {name}Composer {{ std::shared_ptr verification_key; // The crs_factory holds the path to the srs and exposes methods to extract the srs elements - std::shared_ptr> crs_factory_; + std::shared_ptr> crs_factory_; // The commitment key is passed to the prover but also used herein to compute the verfication key commitments std::shared_ptr commitment_key; @@ -140,7 +140,7 @@ class {name}Composer {{ {name}Composer() {{ - crs_factory_ = barretenberg::srs::get_crs_factory(); + crs_factory_ = bb::srs::get_crs_factory(); }} {name}Composer(std::shared_ptr p_key, std::shared_ptr v_key) @@ -162,7 +162,7 @@ class {name}Composer {{ {name}Prover create_prover(CircuitConstructor& circuit_constructor); {name}Verifier create_verifier(CircuitConstructor& circuit_constructor); - void add_table_column_selector_poly_to_proving_key(barretenberg::polynomial& small, const std::string& tag); + void add_table_column_selector_poly_to_proving_key(bb::polynomial& small, const std::string& tag); void compute_commitment_key(size_t circuit_size) {{ @@ -170,7 +170,7 @@ class {name}Composer {{ }}; }}; -}} // namespace proof_system::honk +}} // namespace bb::honk " ); diff --git a/bberg/src/flavor_builder.rs b/bberg/src/flavor_builder.rs index fc31470f0a..4c847ff098 100644 --- a/bberg/src/flavor_builder.rs +++ b/bberg/src/flavor_builder.rs @@ -69,7 +69,7 @@ impl FlavorBuilder for BBFiles { " {includes} -namespace proof_system::honk::flavor {{ +namespace bb::honk::flavor {{ class {name}Flavor {{ public: @@ -101,7 +101,7 @@ class {name}Flavor {{ {transcript} }}; -}} // namespace proof_system::honk +}} // namespace bb::honk " @@ -165,7 +165,7 @@ fn create_class_aliases() -> &'static str { using PCS = pcs::kzg::KZG; using FF = G1::subgroup_field; - using Polynomial = barretenberg::Polynomial; + using Polynomial = bb::Polynomial; using PolynomialHandle = std::span; using GroupElement = G1::element; using Commitment = G1::affine_element; @@ -408,7 +408,7 @@ fn create_polynomial_views(first_poly: &String) -> String { * @details During folding and sumcheck, the prover evaluates the relations on these univariates. */ template - using ProverUnivariates = AllEntities>; + using ProverUnivariates = AllEntities>; /** * @brief A container for univariates produced during the hot loop in sumcheck. @@ -507,7 +507,7 @@ fn generate_transcript(witness: &[String]) -> String { {declarations} - std::vector> sumcheck_univariates; + std::vector> sumcheck_univariates; std::array sumcheck_evaluations; std::vector zm_cq_comms; Commitment zm_cq_comm; @@ -529,7 +529,7 @@ fn generate_transcript(witness: &[String]) -> String { for (size_t i = 0; i < log_n; ++i) {{ sumcheck_univariates.emplace_back( - deserialize_from_buffer>( + deserialize_from_buffer>( Transcript::proof_data, num_bytes_read)); }} sumcheck_evaluations = deserialize_from_buffer>( diff --git a/bberg/src/lookup_builder.rs b/bberg/src/lookup_builder.rs index ab79660bf7..279695f971 100644 --- a/bberg/src/lookup_builder.rs +++ b/bberg/src/lookup_builder.rs @@ -203,7 +203,7 @@ fn create_lookup_settings_file(lookup: &Lookup) -> String { " {lookup_settings_includes} - namespace proof_system::honk::sumcheck {{ + namespace bb::honk::sumcheck {{ /** * @brief This class contains an example of how to set LookupSettings classes used by the diff --git a/bberg/src/permutation_builder.rs b/bberg/src/permutation_builder.rs index f64825a03e..78bf0b5dd4 100644 --- a/bberg/src/permutation_builder.rs +++ b/bberg/src/permutation_builder.rs @@ -163,7 +163,7 @@ fn create_permutation_settings_file(permutation: &Permutation) -> String { " {permutation_settings_includes} - namespace proof_system::honk::sumcheck {{ + namespace bb::honk::sumcheck {{ class {permutation_name}_permutation_settings {{ public: diff --git a/bberg/src/prover_builder.rs b/bberg/src/prover_builder.rs index c28d9fdaf6..81280652fb 100644 --- a/bberg/src/prover_builder.rs +++ b/bberg/src/prover_builder.rs @@ -11,7 +11,7 @@ impl ProverBuilder for BBFiles { let include_str = includes_hpp(name); let prover_hpp = format!(" {include_str} - namespace proof_system::honk {{ + namespace bb::honk {{ class {name}Prover {{ @@ -41,7 +41,7 @@ impl ProverBuilder for BBFiles { std::vector public_inputs; - proof_system::RelationParameters relation_parameters; + bb::RelationParameters relation_parameters; std::shared_ptr key; @@ -62,7 +62,7 @@ impl ProverBuilder for BBFiles { plonk::proof proof; }}; - }} // namespace proof_system::honk + }} // namespace bb::honk "); self.write_file(&self.prover, &format!("{}_prover.hpp", name), &prover_hpp); @@ -74,7 +74,7 @@ impl ProverBuilder for BBFiles { let prover_cpp = format!(" {include_str} - namespace proof_system::honk {{ + namespace bb::honk {{ using Flavor = honk::flavor::{name}Flavor; @@ -92,13 +92,13 @@ impl ProverBuilder for BBFiles { , commitment_key(commitment_key) {{ for (auto [prover_poly, key_poly] : zip_view(prover_polynomials.get_unshifted(), key->get_all())) {{ - ASSERT(proof_system::flavor_get_label(prover_polynomials, prover_poly) == - proof_system::flavor_get_label(*key, key_poly)); + ASSERT(bb::flavor_get_label(prover_polynomials, prover_poly) == + bb::flavor_get_label(*key, key_poly)); prover_poly = key_poly.share(); }} for (auto [prover_poly, key_poly] : zip_view(prover_polynomials.get_shifted(), key->get_to_be_shifted())) {{ - ASSERT(proof_system::flavor_get_label(prover_polynomials, prover_poly) == - proof_system::flavor_get_label(*key, key_poly) + \"_shift\"); + ASSERT(bb::flavor_get_label(prover_polynomials, prover_poly) == + bb::flavor_get_label(*key, key_poly) + \"_shift\"); prover_poly = key_poly.shifted(); }} }} @@ -201,7 +201,7 @@ impl ProverBuilder for BBFiles { return export_proof(); }} - }} // namespace proof_system::honk + }} // namespace bb::honk "); diff --git a/bberg/src/relation_builder.rs b/bberg/src/relation_builder.rs index e5b588fca4..ae26efcf7b 100644 --- a/bberg/src/relation_builder.rs +++ b/bberg/src/relation_builder.rs @@ -135,7 +135,7 @@ impl RelationBuilder for BBFiles { let relations = format!( "{includes} -namespace proof_system::{root_name}_vm {{ +namespace bb::{root_name}_vm {{ {row_type}; diff --git a/bberg/src/verifier_builder.rs b/bberg/src/verifier_builder.rs index 9468b6e148..9c2c199e4c 100644 --- a/bberg/src/verifier_builder.rs +++ b/bberg/src/verifier_builder.rs @@ -20,10 +20,10 @@ impl VerifierBuilder for BBFiles { let ver_cpp = format!(" {include_str} - using namespace barretenberg; - using namespace proof_system::honk::sumcheck; + using namespace bb; + using namespace bb::honk::sumcheck; - namespace proof_system::honk {{ + namespace bb::honk {{ {name}Verifier::{name}Verifier(std::shared_ptr verifier_key) : key(verifier_key) {{}} @@ -106,7 +106,7 @@ impl VerifierBuilder for BBFiles { }} - }} // namespace proof_system::honk + }} // namespace bb::honk "); @@ -120,7 +120,7 @@ impl VerifierBuilder for BBFiles { " {include_str} - namespace proof_system::honk {{ + namespace bb::honk {{ class {name}Verifier {{ using Flavor = honk::flavor::{name}Flavor; using FF = Flavor::FF; @@ -145,7 +145,7 @@ impl VerifierBuilder for BBFiles { std::shared_ptr transcript; }}; - }} // namespace proof_system::honk + }} // namespace bb::honk "