<commit_before>function Application (applicationNode) {

    // DOM Templates
    var T_APPLICATION   = '<div id="application"></div>',
        T_CONTROLS      = '<div id="controls"></div>';
        T_SLIDERS       = '<div id="sliders"></div>';
        T_VISUAL        = '<div id="visual"></div>';

    // DOM Nodes
    var rootNode        = $(T_APPLICATION),
        controlsNode    = $(T_CONTROLS),
        sliderNode      = $(T_SLIDERS),
        visualNode      = $(T_VISUAL);

    // Build that DOM
    rootNode.append(controlsNode);
    rootNode.append(sliderNode);
    rootNode.append(visualNode);
    $(applicationNode).append(rootNode);

    // Build Objects
    var dataSource  = new Humble.DataSource(),
        model       = new Humble.Model(),
        controls    = new Humble.Controls(controlsNode, model),
        sliders     = new Humble.Sliders(sliderNode, model),
        visual      = new Humble.Visual(visualNode, model);

    // Controller
    controls.incomeChange(function (e, ui) {
        
    });

    // Fucking callback
    var callback = {
        success : onDataSuccess
    }
    dataSource.request({callback : callback});

    // Update Shit
    sliderNode.delegate('.slider', 'slide', function (e, ui) {

        var key = $(this).data('key');

        visual.update(key, ui.value);
    });

    /**
     * Handle Data Source Success
     */
    function onDataSuccess (data) {

        model.setXML(data);

        controls.update();
        sliders.update();
        visual.draw();
    }
}

Application('body');
<commit_msg>Apply translation of slider value when updating visual.<commit_after>function Application (applicationNode) {

    // DOM Templates
    var T_APPLICATION   = '<div id="application"></div>',
        T_CONTROLS      = '<div id="controls"></div>';
        T_SLIDERS       = '<div id="sliders"></div>';
        T_VISUAL        = '<div id="visual"></div>';

    // DOM Nodes
    var rootNode        = $(T_APPLICATION),
        controlsNode    = $(T_CONTROLS),
        sliderNode      = $(T_SLIDERS),
        visualNode      = $(T_VISUAL);

    // Build that DOM
    rootNode.append(controlsNode);
    rootNode.append(sliderNode);
    rootNode.append(visualNode);
    $(applicationNode).append(rootNode);

    // Build Objects
    var dataSource  = new Humble.DataSource(),
        model       = new Humble.Model(),
        controls    = new Humble.Controls(controlsNode, model),
        sliders     = new Humble.Sliders(sliderNode, model),
        visual      = new Humble.Visual(visualNode, model);

    // Controller
    controls.incomeChange(function (e, ui) {
        
    });

    // Fucking callback
    var callback = {
        success : onDataSuccess
    }
    dataSource.request({callback : callback});

    // Update Shit
    sliderNode.delegate('.slider', 'slide', function (e, ui) {

        var key   = $(this).data('key'),
            value = sliders.translateB(ui.value);

        visual.update(key, value);
    });

    /**
     * Handle Data Source Success
     */
    function onDataSuccess (data) {

        model.setXML(data);

        controls.update();
        sliders.update();
        visual.draw();
    }
}

Application('body');

{'fraction_non_alphanumeric': 0.1384471468662301, 'fraction_numerical': 0.0, 'mean_word_length': 2.166831194471866, 'pattern_counts': {'":': 0, '<': 19, '<?xml version=': 0, '>': 19, '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': '574886', 'n_tokens_mistral': 950, 'n_tokens_neox': 904, 'n_words': 195}