<commit_before>.. module:: kaa.strutils
   :synopsis: String utility functions

Utility Functions
=================

String
------

The following two functions (py3_str() and py3_b()) are commonly used utility functions,
and so they are exposed directly in the kaa namespace.

.. autofunction:: kaa.py3_str
.. autofunction:: kaa.py3_b
.. autofunction:: kaa.strutils.utf8
.. autofunction:: kaa.strutils.get_encoding
.. autofunction:: kaa.strutils.set_encoding
.. autofunction:: kaa.strutils.format
.. attribute:: kaa.strutils.BYTES_TYPE
.. attribute:: kaa.strutils.UNICODE_TYPE

<commit_msg>Add missing utility functions to documentation<commit_after>.. module:: kaa.strutils
   :synopsis: String utility functions

Utility Functions
=================

String
------

The following two functions (py3_str() and py3_b()) are commonly used utility functions,
and so they are exposed directly in the kaa namespace.

.. autofunction:: kaa.py3_str
.. autofunction:: kaa.py3_b
.. autofunction:: kaa.strutils.nativestr
.. autofunction:: kaa.strutils.fsname
.. autofunction:: kaa.strutils.utf8
.. autofunction:: kaa.strutils.get_encoding
.. autofunction:: kaa.strutils.set_encoding
.. autofunction:: kaa.strutils.format
.. attribute:: kaa.strutils.BYTES_TYPE
.. attribute:: kaa.strutils.UNICODE_TYPE


{'fraction_non_alphanumeric': 0.14396284829721362, 'fraction_numerical': 0.007739938080495356, 'mean_word_length': 4.573275862068965, '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': '4958591', 'n_tokens_mistral': 417, 'n_tokens_neox': 412, 'n_words': 105}