<commit_before>import tempfile
import bloscpack
import blosc
import pickle
import os
from os import mkdir
from os.path import exists, isdir, join
import pandas as pd
import numpy as np
from pandas import msgpack
import shutil
from pandas.core.indexing import convert_to_index_sliceable


def escape(text):
    return str(text)


def _safe_mkdir(path):
    if not exists(path):
        mkdir(path)


class Castra(object):
    def __init__(self, path=None, template=None):
        # check if we should create a random path<commit_msg>remove unused import<commit_after>import tempfile
import bloscpack
import blosc
import pickle
import os
from os import mkdir
from os.path import exists, isdir, join
import pandas as pd
import numpy as np
from pandas import msgpack
import shutil


def escape(text):
    return str(text)


def _safe_mkdir(path):
    if not exists(path):
        mkdir(path)


class Castra(object):
    def __init__(self, path=None, template=None):
        # check if we should create a random path
{'fraction_non_alphanumeric': 0.06132542037586548, 'fraction_numerical': 0.0, 'mean_word_length': 4.18974358974359, 'pattern_counts': {'":': 0, '<': 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': '3164779', 'n_tokens_mistral': 311, 'n_tokens_neox': 295, 'n_words': 121}