<commit_before>var search = document.getElementById("search");

function boo() {
  //Reset search.value
  search.value = "(";

  //extract function
  function extract(x) {
    if (/\w/.test(x.value)) {
      var y = x.value.toLowerCase().split("\n");
      for (var i = 0; i < y.length; i++) {
        y[i] = y[i].trim();
      }
      concepts.push(y);
    }
  }

  //extract concepts and add to concepts array
  var concept = document.querySelectorAll(".concept");
  var concepts = [];
  for (var i = 0; i < concept.length; i++) {
    extract(concept[i]);
  }

  //look for phrases
  for (var i = 0; i < concepts.length; i++) {
    for (var j = 0; j < concepts[i].length; j++) {<commit_msg>Added conditional to extract function to remove empty array elements<commit_after>var search = document.getElementById("search");

function boo() {
  //Reset search.value
  search.value = "(";

  //extract function
  function extract(x) {
    if (/\w|\d/.test(x.value)) {
      var y = x.value.toLowerCase().split("\n");
      for (var i = 0; i < y.length; i++) {
        y[i] = y[i].trim();
        if (!(/\w|\d/.test(y[i]))) {
        	y.splice(i, 1);
          i--;
        }
      }
      concepts.push(y);
    }
  }
  //extract concepts and add to concepts array
  var concept = document.querySelectorAll(".concept");
  var concepts = [];
  for (var i = 0; i < concept.length; i++) {
    extract(concept[i]);
  }

  //look for phrases
  for (var i = 0; i < concepts.length; i++) {
    for (var j = 0; j < concepts[i].length; j++) {
{'fraction_non_alphanumeric': 0.18651832460732984, 'fraction_numerical': 0.0058900523560209425, 'mean_word_length': 2.4129464285714284, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 3, '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': '383739', 'n_tokens_mistral': 529, 'n_tokens_neox': 515, 'n_words': 142}