<commit_before>import asyncio
import logging
import threading
import tkinter as tk
import tkinter.ttk as ttk
from tkinter import filedialog, messagebox
import webbrowser
import json

from modis.tools import data, config

logger = logging.getLogger(__name__)


class Frame(ttk.Frame):
    """A tab containing the core controls of the bot"""

    def __init__(self, parent):
        """Create the frame.

        Args:
            parent: A tk or ttk object.
        """

        super(Frame, self).__init__(parent, padding=8)

        # Add elements
        info = self.Info(self)
        control = self.Control(self)
        log = self.Log(self)

        # Grid elements
        info.grid(column=0, row=0, padx=8, pady=8, stick="W E N S")
        control.grid(column=1, row=0, padx=8, pady=8, sticky="W E N S")
        log.grid(column=0, columnspan=2, row=1, padx=8, pady=8, sticky="W E N S")

        # Configure stretch ratios
        self.columnconfigure(0, weight=0)
        self.columnconfigure(1, weight=1)
        self.rowconfigure(0, weight=0)
        self.rowconfigure(1, weight=1)

    class Info(ttk.LabelFrame):
        """The control panel for the Modis bot."""

        def __init__(self, parent):
            """Create the frame.

            Args:
                parent: A tk or ttk object.
            """

            super(Frame.Info, self).__init__(parent, padding=8, text="Info")

            # Variables
            self.invite_text = tk.StringVar(value="Paste Client ID here for invite link")

            # Add elements
            def hyperlink_website(event):
                webbrowser.open_new("https://modisworks.github.io/")

            def hyperlink_discord(event):
                webbrowser.open_new("https://discord.gg/z83UGvK/")<commit_msg>Modified discord invite link<commit_after>import asyncio
import logging
import threading
import tkinter as tk
import tkinter.ttk as ttk
from tkinter import filedialog, messagebox
import webbrowser
import json

from modis.tools import data, config

logger = logging.getLogger(__name__)


class Frame(ttk.Frame):
    """A tab containing the core controls of the bot"""

    def __init__(self, parent):
        """Create the frame.

        Args:
            parent: A tk or ttk object.
        """

        super(Frame, self).__init__(parent, padding=8)

        # Add elements
        info = self.Info(self)
        control = self.Control(self)
        log = self.Log(self)

        # Grid elements
        info.grid(column=0, row=0, padx=8, pady=8, stick="W E N S")
        control.grid(column=1, row=0, padx=8, pady=8, sticky="W E N S")
        log.grid(column=0, columnspan=2, row=1, padx=8, pady=8, sticky="W E N S")

        # Configure stretch ratios
        self.columnconfigure(0, weight=0)
        self.columnconfigure(1, weight=1)
        self.rowconfigure(0, weight=0)
        self.rowconfigure(1, weight=1)

    class Info(ttk.LabelFrame):
        """The control panel for the Modis bot."""

        def __init__(self, parent):
            """Create the frame.

            Args:
                parent: A tk or ttk object.
            """

            super(Frame.Info, self).__init__(parent, padding=8, text="Info")

            # Variables
            self.invite_text = tk.StringVar(value="Paste Client ID here for invite link")

            # Add elements
            def hyperlink_website(event):
                webbrowser.open_new("https://modisworks.github.io/")

            def hyperlink_discord(event):
                webbrowser.open_new("https://modisworks.github.io/#getting-started")
{'fraction_non_alphanumeric': 0.11095623083356565, 'fraction_numerical': 0.013381655979927517, 'mean_word_length': 2.288725939505041, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, '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': '3181930', 'n_tokens_mistral': 1120, 'n_tokens_neox': 1069, 'n_words': 294}