<commit_before>(function(d) {

  var i, count = 0;

  var metas = d.head.getElementsByTagName('meta');
  var baseurl = 'http://lab.lepture.com/github-cards/card.html'
  var client_id, client_secret;
  for (i = 0; i < metas.length; i++) {
    if (metas[i].getAttribute('name') == 'gc:url') {
      baseurl = metas[i].getAttribute('content');
    } else if (metas[i].getAttribute('name') == 'gc:client-id') {
      client_id = metas[i].getAttribute('content');
    } else if (metas[i].getAttribute('name') == 'gc:client-secret') {
      client_secret = metas[i].getAttribute('content');
    }
  }

  function queryclass(name) {
    if (d.querySelectorAll) {
      return d.querySelectorAll('.' + name);
    }
    var elements = d.getElementsByTagName('div');
    var ret = [];
    for (i = 0; i < elements.length; i++) {
      if (~elements[i].className.split(' ').indexOf(name)) {
        ret.push(elements[i]);
      }
    }
    return ret;
  }

  function querydata(element, name) {
    return element.getAttribute('data-' + name);
  }<commit_msg>query meta from document.<commit_after>(function(d) {

  var i, count = 0;

  var metas = d.getElementsByTagName('meta');
  var baseurl = 'http://lab.lepture.com/github-cards/card.html'
  var client_id, client_secret;
  for (i = 0; i < metas.length; i++) {
    if (metas[i].getAttribute('name') == 'gc:url') {
      baseurl = metas[i].getAttribute('content');
    } else if (metas[i].getAttribute('name') == 'gc:client-id') {
      client_id = metas[i].getAttribute('content');
    } else if (metas[i].getAttribute('name') == 'gc:client-secret') {
      client_secret = metas[i].getAttribute('content');
    }
  }

  function queryclass(name) {
    if (d.querySelectorAll) {
      return d.querySelectorAll('.' + name);
    }
    var elements = d.getElementsByTagName('div');
    var ret = [];
    for (i = 0; i < elements.length; i++) {
      if (~elements[i].className.split(' ').indexOf(name)) {
        ret.push(elements[i]);
      }
    }
    return ret;
  }

  function querydata(element, name) {
    return element.getAttribute('data-' + name);
  }
{'fraction_non_alphanumeric': 0.18544935805991442, 'fraction_numerical': 0.0028530670470756064, 'mean_word_length': 3.191235059760956, 'pattern_counts': {'":': 0, '<': 7, '<?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': '6907964', 'n_tokens_mistral': 726, 'n_tokens_neox': 726, 'n_words': 137}