<commit_before>Optional speedup extension
===========================

Why?
-------

charset-normalizer will always remain pure Python, meaning that a environment without any build-capabilities will
run this program without any additional requirements.

Nonetheless, starting from the version 3.0 we introduce and publish some platform specific wheels including a
pre-build extension.

Most of the time is spent in the module `md.py` so we decided to "compile it" using Mypyc.

(1) It does not require to have a separate code base
(2) Our project code base is rather simple and lightweight
(3) Mypyc is robust enough today
(4) Four times faster!

How?
-------

If your platform and/or architecture is not served by this swift optimization you may compile it easily yourself.
Following those instructions (provided you have the necessary toolchain installed):

  ::

    export CHARSET_NORMALIZER_USE_MYPYC=1
    pip install charset-normalizer --no-binary :all:


How not to?
-----------

You may install charset-normalizer without any specific (pre-built wheel) by directly using the universal wheel
(most likely hosted on PyPi or any valid mirror you use)

  ::

    pip install charset-normalizer --no-binary :all:

Directly.
<commit_msg>:pencil: Adjust speedup docs section<commit_after>Optional speedup extension
===========================

Why?
-------

charset-normalizer will always remain pure Python, meaning that a environment without any build-capabilities will
run this program without any additional requirements.

Nonetheless, starting from the version 3.0 we introduce and publish some platform specific wheels including a
pre-build extension.

Most of the time is spent in the module `md.py` so we decided to "compile it" using Mypyc.

(1) It does not require to have a separate code base
(2) Our project code base is rather simple and lightweight
(3) Mypyc is robust enough today
(4) Four times faster!

How?
-------

If your platform and/or architecture is not served by this swift optimization you may compile it easily yourself.
Following those instructions (provided you have the necessary toolchain installed):

  ::

    export CHARSET_NORMALIZER_USE_MYPYC=1
    pip install mypy build wheel
    pip install charset-normalizer --no-binary :all:


How not to?
-----------

You may install charset-normalizer without any specific (pre-built wheel) by directly using the universal wheel
(most likely hosted on PyPi or any valid mirror you use)

  ::

    pip install charset-normalizer --no-binary :all:

Directly.

{'fraction_non_alphanumeric': 0.08753943217665615, 'fraction_numerical': 0.005520504731861199, 'mean_word_length': 4.013833992094861, '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': '7628476', 'n_tokens_mistral': 660, 'n_tokens_neox': 629, 'n_words': 335}