<commit_before>require(window.APT_OPTIONS.configObject,
	['underscore', 'js/quickvm_sup', 'moment',
	 'js/lib/text!template/dashboard.html'],
function (_, sup, moment, dashboardString)
{
    'use strict';
    var isadmin           = 0;
    var dashboardTemplate = _.template(dashboardString);

    function initialize()
    {
	window.APT_OPTIONS.initialize(sup);
	isadmin = window.ISADMIN;

	DashboardLoop();
	setInterval(DashboardLoop,5000);

	setInterval(UpdateTimes,1000);
    }

    function DashboardLoop()
    {
	var callback = function(json) {
	    console.log(json);
	    
	    var dashboard_html = dashboardTemplate({"dashboard": json.value,
						    "isadmin": isadmin});
	    $('#page-body').html(dashboard_html);

	    $('#last-refresh').data("time",new Date());
	    
	    // Format dates with moment before display.
	    $('.format-date').each(function() {
		var date = $.trim($(this).html());
		if (date != "") {
		    $(this).html(moment($(this).html())
				 .format("ddd h:mm A"));
		}
	    });
	    UpdateTimes();
	}<commit_msg>Bump timer to 30 seconds from 5 seconds.<commit_after>require(window.APT_OPTIONS.configObject,
	['underscore', 'js/quickvm_sup', 'moment',
	 'js/lib/text!template/dashboard.html'],
function (_, sup, moment, dashboardString)
{
    'use strict';
    var isadmin           = 0;
    var dashboardTemplate = _.template(dashboardString);

    function initialize()
    {
	window.APT_OPTIONS.initialize(sup);
	isadmin = window.ISADMIN;

	DashboardLoop();
	setInterval(DashboardLoop,5000);
	setInterval(UpdateTimes,1000);
    }

    function DashboardLoop()
    {
	var callback = function(json) {
	    console.log(json);
	    
	    var dashboard_html = dashboardTemplate({"dashboard": json.value,
						    "isadmin": isadmin});
	    $('#page-body').html(dashboard_html);
	    $('#last-refresh').data("time",new Date());
	    
	    // Format dates with moment before display.
	    $('.format-date').each(function() {
		var date = $.trim($(this).html());
		if (date != "") {
		    $(this).html(moment($(this).html())
				 .format("ddd h:mm A"));
		}
	    });
	    UpdateTimes();
	}
{'fraction_non_alphanumeric': 0.171307220386975, 'fraction_numerical': 0.009910335063709298, 'mean_word_length': 3.353182751540041, 'pattern_counts': {'":': 4, '<': 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': '4301358', 'n_tokens_mistral': 742, 'n_tokens_neox': 669, 'n_words': 121}