<commit_before>setInterval(function(){
   var numdevices = 5;
   $.ajax({
      url: "/poll",
      global: false,
      type: "POST",
      cache: false,
      success: function(response){
         console.log(response);
      }});
},3000);<commit_msg>web: finished poller<commit_after>setInterval(function(){
   var numdevices = 5;
   var state;
   $.ajax({
      url: "/poll",
      global: false,
      type: "POST",
      cache: false,
      success: function(response){
         for (var key in response) {
            if (response.hasOwnProperty(key)) {
               switch_button = $("li[lid='" + key + "']").find('input');
               if (response[key] == '0'){
                  state = false;
               }else if (response[key] == '1'){
                  state = true;
               }
               console.log(state);
               switch_button.bootstrapSwitch('state',state);
               state = null;
            }
         }
      }});
},3000);
{'fraction_non_alphanumeric': 0.15487179487179487, 'fraction_numerical': 0.012307692307692308, 'mean_word_length': 1.659400544959128, 'pattern_counts': {'":': 0, '<': 3, '<?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': '1740633', 'n_tokens_mistral': 286, 'n_tokens_neox': 276, 'n_words': 62}