<commit_before>var ddg_spice_lastfm_album = function(api_result) {
    "use strict";

    var skip = {
        "album": 1,
        "albums": 1,
        "records": 1,
        "cd": 1,
        "cds": 1
    };

    // Don't do anything if we find an error.
    if(api_result.error || !api_result.album || !api_result.album.name || !api_result.album.artist) {
        return;
    }

    // Display the spice plugin.
    // Check if it's relevant and see if it's popular enough (this is just a guess--we need to improve on this).
    if(DDG.isRelevant(api_result.album.name, skip) && DDG.isRelevant(api_result.album.artist, skip) &&
        +api_result.album.playcount > 1000) {
        Spice.render({
            data              : api_result,
            force_big_header  : true,
            header1           : api_result.album.name + " (Album)",
            source_name       : "Last.fm",
            source_url        : api_result.album.url,
            template_normal   : "album"
        });

        $(document).ready(function() {
            $("#expand").click(function() {
                DDG.toggle("all", 1);
                DDG.toggle("some", -1);
                DDG.toggle("expand", -1);
            });
        });
    }
};

// Shortens the date.<commit_msg>Album: Added more comments.<commit_after>var ddg_spice_lastfm_album = function(api_result) {
    "use strict";

    var skip = {
        "album": 1,
        "albums": 1,
        "records": 1,
        "cd": 1,
        "cds": 1
    };

    // Don't do anything if we find an error.
    if(api_result.error || !api_result.album || !api_result.album.name || !api_result.album.artist) {
        return;
    }

    // Display the spice plugin.
    // Check if it's relevant and see if it's popular enough (this is just a guess--we need to improve on this).
    // This successfully blocks:
    // - girl on fire album by alicia (Returns the wrong person. Maybe Last.fm has some sort of useCanonical?)
    // - circus album by eraserhead
    if(DDG.isRelevant(api_result.album.name, skip) && DDG.isRelevant(api_result.album.artist, skip) &&
        +api_result.album.playcount > 1000) {
        Spice.render({
            data              : api_result,
            force_big_header  : true,
            header1           : api_result.album.name + " (Album)",
            source_name       : "Last.fm",
            source_url        : api_result.album.url,
            template_normal   : "album"
        });

        $(document).ready(function() {
            $("#expand").click(function() {
                DDG.toggle("all", 1);
                DDG.toggle("some", -1);
                DDG.toggle("expand", -1);
            });
        });
    }
};

// Shortens the date.
{'fraction_non_alphanumeric': 0.13523391812865498, 'fraction_numerical': 0.009502923976608187, 'mean_word_length': 1.7260956175298805, 'pattern_counts': {'":': 10, '<': 3, '<?xml version=': 0, '>': 5, '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': '2472300', 'n_tokens_mistral': 885, 'n_tokens_neox': 825, 'n_words': 196}