<commit_before>// included from constructor for function_signatures() in
// src/stan/gm/ast.hpp

std::vector<base_expr_type> base_types;
base_types.push_back(INT_T);
base_types.push_back(DOUBLE_T);
base_types.push_back(VECTOR_T);
base_types.push_back(ROW_VECTOR_T);
base_types.push_back(MATRIX_T);

std::vector<expr_type> vector_types;
vector_types.push_back(DOUBLE_T);                  // scalar
vector_types.push_back(expr_type(DOUBLE_T,1U));    // std vector
vector_types.push_back(VECTOR_T);                  // Eigen vector
vector_types.push_back(ROW_VECTOR_T);              // Eigen row vector

std::vector<expr_type> int_vector_types;
int_vector_types.push_back(INT_T);                  // scalar
int_vector_types.push_back(expr_type(INT_T,1U));    // std vector

std::vector<expr_type> primitive_types;
primitive_types.push_back(INT_T);
primitive_types.push_back(DOUBLE_T);

add_unary("abs");
add("abs",INT_T,INT_T);
add_unary("acos");
add_unary("acosh");
add("add",VECTOR_T,VECTOR_T,VECTOR_T);
add("add",ROW_VECTOR_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("add",MATRIX_T,MATRIX_T,MATRIX_T);
add("add",VECTOR_T,VECTOR_T,DOUBLE_T);
add("add",ROW_VECTOR_T,ROW_VECTOR_T,DOUBLE_T);
add("add",MATRIX_T,MATRIX_T,DOUBLE_T);
add("add",VECTOR_T,DOUBLE_T,VECTOR_T);
add("add",ROW_VECTOR_T,DOUBLE_T,ROW_VECTOR_T);
add("add",MATRIX_T,DOUBLE_T,MATRIX_T);
add_unary("asin");
add_unary("asinh");
add_unary("atan");
add_binary("atan2");
add_unary("atanh");
for (size_t i = 0; i < int_vector_types.size(); ++i) 
  for (size_t j = 0; j < vector_types.size(); ++j)
    add("bernoulli_log",DOUBLE_T,int_vector_types[i],vector_types[j]);
for (size_t i = 0; i < int_vector_types.size(); ++i) 
  for (size_t j = 0; j < vector_types.size(); ++j)
    add("bernoulli_cdf",DOUBLE_T,int_vector_types[i],vector_types[j]);
add("bernoulli_rng",INT_T,DOUBLE_T);
for (size_t i = 0; i < int_vector_types.size(); ++i) 
  for (size_t j = 0; j < vector_types.size(); ++j)
    add("bernoulli_logit_log",DOUBLE_T,int_vector_types[i],vector_types[j]);
for (size_t i = 0; i < int_vector_types.size(); i++) 
  for (size_t j = 0; j < int_vector_types.size(); j++)
    for (size_t k = 0; k < vector_types.size(); k++)
      for (size_t l = 0; l < vector_types.size(); l++) 
        add("beta_binomial_log",DOUBLE_T, // result
            int_vector_types[i],int_vector_types[j],vector_types[k],vector_types[l]);
add("beta_binomial_rng",INT_T,INT_T,DOUBLE_T,DOUBLE_T);
for (size_t i = 0; i < int_vector_types.size(); i++) 
  for (size_t j = 0; j < int_vector_types.size(); j++)
    for (size_t k = 0; k < vector_types.size(); k++)
      for (size_t l = 0; l < vector_types.size(); l++) 
        add("beta_binomial_cdf",DOUBLE_T, // result
            int_vector_types[i],int_vector_types[j],vector_types[k],vector_types[l]);
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("beta_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("beta_cdf",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
add_binary("beta_rng");
add("binary_log_loss",DOUBLE_T,INT_T,DOUBLE_T);
add_binary("binomial_coefficient_log");
for (size_t i = 0; i < int_vector_types.size(); ++i)
  for (size_t j = 0; j < int_vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("binomial_log",DOUBLE_T,int_vector_types[i],int_vector_types[j],vector_types[k]);
add("binomial_rng",INT_T,INT_T,DOUBLE_T);
for (size_t i = 0; i < int_vector_types.size(); ++i)
  for (size_t j = 0; j < int_vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("binomial_cdf",DOUBLE_T,int_vector_types[i],int_vector_types[j],vector_types[k]);
for (size_t i = 0; i < int_vector_types.size(); ++i)
  for (size_t j = 0; j < int_vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("binomial_logit_log",DOUBLE_T,int_vector_types[i],int_vector_types[j],vector_types[k]);
add("categorical_log",DOUBLE_T,INT_T,VECTOR_T);
add("categorical_rng",INT_T,VECTOR_T);
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("cauchy_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
add_binary("cauchy_rng");
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("cauchy_cdf",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
add_unary("cbrt");
add_unary("ceil");
add("cholesky_decompose",MATRIX_T,MATRIX_T);
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
      add("chi_square_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j]); // args
add_unary("chi_square_rng");
add("block",MATRIX_T,MATRIX_T,INT_T,INT_T,INT_T,INT_T);
add("col",VECTOR_T,MATRIX_T,INT_T);
add("cols",INT_T,VECTOR_T);
add("cols",INT_T,ROW_VECTOR_T);
add("cols",INT_T,MATRIX_T);
add("columns_dot_product",ROW_VECTOR_T,MATRIX_T,MATRIX_T);
add("columns_dot_self",ROW_VECTOR_T,MATRIX_T,MATRIX_T);
add_unary("cos");
add_unary("cosh");
add("cumulative_sum", expr_type(DOUBLE_T,1U), expr_type(DOUBLE_T,1U));
add("cumulative_sum", VECTOR_T, VECTOR_T);
add("cumulative_sum", ROW_VECTOR_T, ROW_VECTOR_T);
add("determinant",DOUBLE_T,MATRIX_T);
add("diagonal",VECTOR_T,MATRIX_T);
add("diag_matrix",MATRIX_T,VECTOR_T);
add("dirichlet_log",DOUBLE_T,VECTOR_T,VECTOR_T);
add("dirichlet_rng",VECTOR_T,VECTOR_T);
add("divide",DOUBLE_T,DOUBLE_T,DOUBLE_T);
add("divide",VECTOR_T,VECTOR_T,DOUBLE_T);
add("divide",ROW_VECTOR_T,ROW_VECTOR_T,DOUBLE_T);
add("divide",MATRIX_T,MATRIX_T,DOUBLE_T);
add("dist",DOUBLE_T,VECTOR_T,VECTOR_T);
add("dist",DOUBLE_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("dist",DOUBLE_T,VECTOR_T,ROW_VECTOR_T);
add("dist",DOUBLE_T,ROW_VECTOR_T,VECTOR_T);
add("squared_dist",DOUBLE_T,VECTOR_T,VECTOR_T);
add("squared_dist",DOUBLE_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("squared_dist",DOUBLE_T,VECTOR_T,ROW_VECTOR_T);
add("squared_dist",DOUBLE_T,ROW_VECTOR_T,VECTOR_T);
add("squared_dist",DOUBLE_T,MATRIX_T,MATRIX_T);
add("dot_product",DOUBLE_T,VECTOR_T,VECTOR_T);
add("dot_product",DOUBLE_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("dot_product",DOUBLE_T,VECTOR_T,ROW_VECTOR_T);
add("dot_product",DOUBLE_T,ROW_VECTOR_T,VECTOR_T);
add("dot_product",DOUBLE_T,expr_type(DOUBLE_T,1U),expr_type(DOUBLE_T,1U)); // vectorized
add("dot_self",DOUBLE_T,VECTOR_T);
add("dot_self",DOUBLE_T,ROW_VECTOR_T);
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("double_exponential_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
add_binary("double_exponential_rng");
add_nullary("e");
add("eigenvalues_sym",VECTOR_T,MATRIX_T);
add("eigenvectors_sym",MATRIX_T,MATRIX_T);
add("diag_pre_multiply",MATRIX_T,MATRIX_T,MATRIX_T);
add("diag_pre_multiply",MATRIX_T,VECTOR_T,MATRIX_T);
add("diag_pre_multiply",MATRIX_T,ROW_VECTOR_T,MATRIX_T);
add("diag_post_multiply",MATRIX_T,MATRIX_T,MATRIX_T);
add("diag_post_multiply",MATRIX_T,MATRIX_T,VECTOR_T);
add("diag_post_multiply",MATRIX_T,MATRIX_T,ROW_VECTOR_T);
add_nullary("epsilon");
add_unary("erf");
add_unary("erfc");
add_unary("exp");
add("exp",VECTOR_T,VECTOR_T);
add("exp",ROW_VECTOR_T,ROW_VECTOR_T);
add("exp",MATRIX_T,MATRIX_T);
add_unary("exp2");
add_unary("expm1");
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
      add("exponential_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j]); // args
add_binary("exponential_cdf");
add_unary("exponential_rng");
for (size_t i = 0; i < vector_types.size(); ++i) {<commit_msg>Revert "removed elt_divide and elt_multiply from function sig"<commit_after>// included from constructor for function_signatures() in
// src/stan/gm/ast.hpp

std::vector<base_expr_type> base_types;
base_types.push_back(INT_T);
base_types.push_back(DOUBLE_T);
base_types.push_back(VECTOR_T);
base_types.push_back(ROW_VECTOR_T);
base_types.push_back(MATRIX_T);

std::vector<expr_type> vector_types;
vector_types.push_back(DOUBLE_T);                  // scalar
vector_types.push_back(expr_type(DOUBLE_T,1U));    // std vector
vector_types.push_back(VECTOR_T);                  // Eigen vector
vector_types.push_back(ROW_VECTOR_T);              // Eigen row vector

std::vector<expr_type> int_vector_types;
int_vector_types.push_back(INT_T);                  // scalar
int_vector_types.push_back(expr_type(INT_T,1U));    // std vector

std::vector<expr_type> primitive_types;
primitive_types.push_back(INT_T);
primitive_types.push_back(DOUBLE_T);

add_unary("abs");
add("abs",INT_T,INT_T);
add_unary("acos");
add_unary("acosh");
add("add",VECTOR_T,VECTOR_T,VECTOR_T);
add("add",ROW_VECTOR_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("add",MATRIX_T,MATRIX_T,MATRIX_T);
add("add",VECTOR_T,VECTOR_T,DOUBLE_T);
add("add",ROW_VECTOR_T,ROW_VECTOR_T,DOUBLE_T);
add("add",MATRIX_T,MATRIX_T,DOUBLE_T);
add("add",VECTOR_T,DOUBLE_T,VECTOR_T);
add("add",ROW_VECTOR_T,DOUBLE_T,ROW_VECTOR_T);
add("add",MATRIX_T,DOUBLE_T,MATRIX_T);
add_unary("asin");
add_unary("asinh");
add_unary("atan");
add_binary("atan2");
add_unary("atanh");
for (size_t i = 0; i < int_vector_types.size(); ++i) 
  for (size_t j = 0; j < vector_types.size(); ++j)
    add("bernoulli_log",DOUBLE_T,int_vector_types[i],vector_types[j]);
for (size_t i = 0; i < int_vector_types.size(); ++i) 
  for (size_t j = 0; j < vector_types.size(); ++j)
    add("bernoulli_cdf",DOUBLE_T,int_vector_types[i],vector_types[j]);
add("bernoulli_rng",INT_T,DOUBLE_T);
for (size_t i = 0; i < int_vector_types.size(); ++i) 
  for (size_t j = 0; j < vector_types.size(); ++j)
    add("bernoulli_logit_log",DOUBLE_T,int_vector_types[i],vector_types[j]);
for (size_t i = 0; i < int_vector_types.size(); i++) 
  for (size_t j = 0; j < int_vector_types.size(); j++)
    for (size_t k = 0; k < vector_types.size(); k++)
      for (size_t l = 0; l < vector_types.size(); l++) 
        add("beta_binomial_log",DOUBLE_T, // result
            int_vector_types[i],int_vector_types[j],vector_types[k],vector_types[l]);
add("beta_binomial_rng",INT_T,INT_T,DOUBLE_T,DOUBLE_T);
for (size_t i = 0; i < int_vector_types.size(); i++) 
  for (size_t j = 0; j < int_vector_types.size(); j++)
    for (size_t k = 0; k < vector_types.size(); k++)
      for (size_t l = 0; l < vector_types.size(); l++) 
        add("beta_binomial_cdf",DOUBLE_T, // result
            int_vector_types[i],int_vector_types[j],vector_types[k],vector_types[l]);
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("beta_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("beta_cdf",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
add_binary("beta_rng");
add("binary_log_loss",DOUBLE_T,INT_T,DOUBLE_T);
add_binary("binomial_coefficient_log");
for (size_t i = 0; i < int_vector_types.size(); ++i)
  for (size_t j = 0; j < int_vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("binomial_log",DOUBLE_T,int_vector_types[i],int_vector_types[j],vector_types[k]);
add("binomial_rng",INT_T,INT_T,DOUBLE_T);
for (size_t i = 0; i < int_vector_types.size(); ++i)
  for (size_t j = 0; j < int_vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("binomial_cdf",DOUBLE_T,int_vector_types[i],int_vector_types[j],vector_types[k]);
for (size_t i = 0; i < int_vector_types.size(); ++i)
  for (size_t j = 0; j < int_vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("binomial_logit_log",DOUBLE_T,int_vector_types[i],int_vector_types[j],vector_types[k]);
add("categorical_log",DOUBLE_T,INT_T,VECTOR_T);
add("categorical_rng",INT_T,VECTOR_T);
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("cauchy_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
add_binary("cauchy_rng");
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("cauchy_cdf",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
add_unary("cbrt");
add_unary("ceil");
add("cholesky_decompose",MATRIX_T,MATRIX_T);
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
      add("chi_square_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j]); // args
add_unary("chi_square_rng");
add("block",MATRIX_T,MATRIX_T,INT_T,INT_T,INT_T,INT_T);
add("col",VECTOR_T,MATRIX_T,INT_T);
add("cols",INT_T,VECTOR_T);
add("cols",INT_T,ROW_VECTOR_T);
add("cols",INT_T,MATRIX_T);
add("columns_dot_product",ROW_VECTOR_T,MATRIX_T,MATRIX_T);
add("columns_dot_self",ROW_VECTOR_T,MATRIX_T,MATRIX_T);
add_unary("cos");
add_unary("cosh");
add("cumulative_sum", expr_type(DOUBLE_T,1U), expr_type(DOUBLE_T,1U));
add("cumulative_sum", VECTOR_T, VECTOR_T);
add("cumulative_sum", ROW_VECTOR_T, ROW_VECTOR_T);
add("determinant",DOUBLE_T,MATRIX_T);
add("diagonal",VECTOR_T,MATRIX_T);
add("diag_matrix",MATRIX_T,VECTOR_T);
add("dirichlet_log",DOUBLE_T,VECTOR_T,VECTOR_T);
add("dirichlet_rng",VECTOR_T,VECTOR_T);
add("divide",DOUBLE_T,DOUBLE_T,DOUBLE_T);
add("divide",VECTOR_T,VECTOR_T,DOUBLE_T);
add("divide",ROW_VECTOR_T,ROW_VECTOR_T,DOUBLE_T);
add("divide",MATRIX_T,MATRIX_T,DOUBLE_T);
add("dist",DOUBLE_T,VECTOR_T,VECTOR_T);
add("dist",DOUBLE_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("dist",DOUBLE_T,VECTOR_T,ROW_VECTOR_T);
add("dist",DOUBLE_T,ROW_VECTOR_T,VECTOR_T);
add("squared_dist",DOUBLE_T,VECTOR_T,VECTOR_T);
add("squared_dist",DOUBLE_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("squared_dist",DOUBLE_T,VECTOR_T,ROW_VECTOR_T);
add("squared_dist",DOUBLE_T,ROW_VECTOR_T,VECTOR_T);
add("squared_dist",DOUBLE_T,MATRIX_T,MATRIX_T);
add("dot_product",DOUBLE_T,VECTOR_T,VECTOR_T);
add("dot_product",DOUBLE_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("dot_product",DOUBLE_T,VECTOR_T,ROW_VECTOR_T);
add("dot_product",DOUBLE_T,ROW_VECTOR_T,VECTOR_T);
add("dot_product",DOUBLE_T,expr_type(DOUBLE_T,1U),expr_type(DOUBLE_T,1U)); // vectorized
add("dot_self",DOUBLE_T,VECTOR_T);
add("dot_self",DOUBLE_T,ROW_VECTOR_T);
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
    for (size_t k = 0; k < vector_types.size(); ++k)
      add("double_exponential_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j], vector_types[k]); // args
add_binary("double_exponential_rng");
add_nullary("e");
add("eigenvalues_sym",VECTOR_T,MATRIX_T);
add("eigenvectors_sym",MATRIX_T,MATRIX_T);
add("elt_divide",VECTOR_T,VECTOR_T,VECTOR_T);
add("elt_divide",ROW_VECTOR_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("elt_divide",MATRIX_T,MATRIX_T,MATRIX_T);
add("elt_multiply",VECTOR_T,VECTOR_T,VECTOR_T);
add("elt_multiply",ROW_VECTOR_T,ROW_VECTOR_T,ROW_VECTOR_T);
add("elt_multiply",MATRIX_T,MATRIX_T,MATRIX_T);
add("diag_pre_multiply",MATRIX_T,MATRIX_T,MATRIX_T);
add("diag_pre_multiply",MATRIX_T,VECTOR_T,MATRIX_T);
add("diag_pre_multiply",MATRIX_T,ROW_VECTOR_T,MATRIX_T);
add("diag_post_multiply",MATRIX_T,MATRIX_T,MATRIX_T);
add("diag_post_multiply",MATRIX_T,MATRIX_T,VECTOR_T);
add("diag_post_multiply",MATRIX_T,MATRIX_T,ROW_VECTOR_T);
add_nullary("epsilon");
add_unary("erf");
add_unary("erfc");
add_unary("exp");
add("exp",VECTOR_T,VECTOR_T);
add("exp",ROW_VECTOR_T,ROW_VECTOR_T);
add("exp",MATRIX_T,MATRIX_T);
add_unary("exp2");
add_unary("expm1");
for (size_t i = 0; i < vector_types.size(); ++i)
  for (size_t j = 0; j < vector_types.size(); ++j)
      add("exponential_log",
          DOUBLE_T, // result
          vector_types[i], vector_types[j]); // args
add_binary("exponential_cdf");
add_unary("exponential_rng");
for (size_t i = 0; i < vector_types.size(); ++i) {
{'fraction_non_alphanumeric': 0.1763200190487529, 'fraction_numerical': 0.006190844693136496, 'mean_word_length': 6.374890254609307, 'pattern_counts': {'":': 0, '<': 97, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4721476', 'n_tokens_mistral': 7270, 'n_tokens_neox': 7360, 'n_words': 1005}