<commit_before>from src.pylex.route import Route


class CategoryRoute(Route):
    def all(self):
        return self._get_json('category/all')

    def broad_categories(self):
        return self._get_json('category/broad-category')

    def lex_categories(self):
        return self._get_json('category/lex-category')

    def lex_types(self):
        return self._get_json('category/lex-type')

    def groups(self):
        return self._get_json('category/group')

    def authors(self):
        return self._get_json('category/author')<commit_msg>Add documentation for category endpoint<commit_after>from src.pylex.route import Route


class CategoryRoute(Route):
    def all(self):
        """
        Return all available categories
        :return: available categories
        :rtype: list
        """
        return self._get_json('category/all')

    def broad_categories(self):
        """
        Return all available broad categories
        :return: broad categories
        :rtype: list
        """
        return self._get_json('category/broad-category')

    def lex_categories(self):
        """
        Return all available LEX categories
        :return: LEX categories
        :rtype: list
        """
        return self._get_json('category/lex-category')

    def lex_types(self):
        """
        Return all available LEX types
        :return: LEX types
        :rtype: list
        """
        return self._get_json('category/lex-type')

    def groups(self):
        """
        Return all available groups
        :return: groups
        :rtype: list
        """
        return self._get_json('category/group')

    def authors(self):
        """
        Return all available authors (people with more than 1 file released on the LEX)
        :return: authors
        :rtype: list
        """
        return self._get_json('category/author')
{'fraction_non_alphanumeric': 0.10250934329951948, 'fraction_numerical': 0.0005339028296849973, 'mean_word_length': 2.2762237762237763, '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': '4515309', 'n_tokens_mistral': 512, 'n_tokens_neox': 492, 'n_words': 128}