<commit_before>chatwrapper = {

    initialized : false,
    visible : false,
    labels: {
        icon : '<i class="fas fa-comments"></i>',
        open : 'Open Chat',
        close : 'Close Chat',
    },

    create_button() {
        const b = document.createElement('button');
        b.style.position = 'fixed';
        b.style.bottom = '0';
        b.id = 'chatwrapper_toggle';
        b.style.right = '10px';
        b.innerHTML = chatwrapper.labels.icon + ' ' + chatwrapper.labels.open;
        b.classList.add('btn');
        b.classList.add('btn-success');
        console.dir(b);
        document.body.appendChild(b);
        return b;
    },

    attach(el) {
        el.addEventListener('click', chatwrapper.toggle);
        chatwrapper.button = el;
    },

    toggle() {
        if (!chatwrapper.initialized) {
            chatwrapper.initialize();
        }
        else if (chatwrapper.visible) {
            chatwrapper.hide();
        }
        else {
            chatwrapper.show();
        }
    },

    initialize() {
        chatwrapper.initialized = true;
        const i = document.createElement('iframe');
        i.src = '/chat';
        i.style.position = 'fixed';
        i.style.bottom = '40px';
        i.style.right = '20px';
        i.style.width = '95%';
        i.style.height = '90%';
        i.style.zIndex = 99999999;
        i.id = 'chatwrapper_window';
        i.style.boxShadow = '10px 20px 30px black';
        console.dir(i);
        document.body.appendChild(i);
        chatwrapper.iframe = i;
        chatwrapper.show();
    },

    show() {
        chatwrapper.visible = true;
        chatwrapper.button.innerHTML = chatwrapper.labels.icon + ' ' + chatwrapper.labels.close;
        chatwrapper.iframe.style.visibility = "visible";
    },
<commit_msg>remove debug<commit_after>chatwrapper = {

    initialized : false,
    visible : false,
    labels: {
        icon : '<i class="fas fa-comments"></i>',
        open : 'Open Chat',
        close : 'Close Chat',
    },

    create_button() {
        const b = document.createElement('button');
        b.style.position = 'fixed';
        b.style.bottom = '0';
        b.id = 'chatwrapper_toggle';
        b.style.right = '10px';
        b.innerHTML = chatwrapper.labels.icon + ' ' + chatwrapper.labels.open;
        b.classList.add('btn');
        b.classList.add('btn-success');
        document.body.appendChild(b);
        return b;
    },

    attach(el) {
        el.addEventListener('click', chatwrapper.toggle);
        chatwrapper.button = el;
    },

    toggle() {
        if (!chatwrapper.initialized) {
            chatwrapper.initialize();
        }
        else if (chatwrapper.visible) {
            chatwrapper.hide();
        }
        else {
            chatwrapper.show();
        }
    },

    initialize() {
        chatwrapper.initialized = true;
        const i = document.createElement('iframe');
        i.src = '/chat';
        i.style.position = 'fixed';
        i.style.bottom = '40px';
        i.style.right = '20px';
        i.style.width = '95%';
        i.style.height = '90%';
        i.style.zIndex = 99999999;
        i.id = 'chatwrapper_window';
        i.style.boxShadow = '10px 20px 30px black';
        document.body.appendChild(i);
        chatwrapper.iframe = i;
        chatwrapper.show();
    },

    show() {
        chatwrapper.visible = true;
        chatwrapper.button.innerHTML = chatwrapper.labels.icon + ' ' + chatwrapper.labels.close;
        chatwrapper.iframe.style.visibility = "visible";
    },

{'fraction_non_alphanumeric': 0.14547504933746827, 'fraction_numerical': 0.014096419509444602, 'mean_word_length': 1.856682769726248, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 2, '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': '5079125', 'n_tokens_mistral': 1086, 'n_tokens_neox': 1047, 'n_words': 183}