Skip to main content

Tokenizers that operate on integer sequences.

Project description

Unit Tokenizer

pytest

Tokenizers that operate on integer sequences.

Requirements

  • Python >= 3.9 (because of type hinting syntax)

Features

  • BPETokenizer

    • Byte-pair encoding algorithm
  • RLETokenizer

    • Run-length encoding algorithm
  • PackBitsTokenizer

    • Modified run-length encoding algorithm
  • NaivePackBitsTokenizer

    • PackBitsTokenizer that allows negative units

Installation

pip install unit-tokenizer

Installation for development

poetry install
pre-commit install

Test

poetry run pytest

Usage

See tests/*.py.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

unit_tokenizer-0.1.7.tar.gz (9.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

unit_tokenizer-0.1.7-py3-none-any.whl (12.7 kB view details)

Uploaded Python 3

File details

Details for the file unit_tokenizer-0.1.7.tar.gz.

File metadata

  • Download URL: unit_tokenizer-0.1.7.tar.gz
  • Upload date:
  • Size: 9.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for unit_tokenizer-0.1.7.tar.gz
Algorithm Hash digest
SHA256 5e09c01a09644f7707259b2564872911f9958abc97092727183d2abcb7e40354
MD5 692043e532753e70eea049dc41c74c76
BLAKE2b-256 6d07737f5e0e184f87fb514b3198bae63753f3124660685ac49afbeaedc52144

See more details on using hashes here.

File details

Details for the file unit_tokenizer-0.1.7-py3-none-any.whl.

File metadata

  • Download URL: unit_tokenizer-0.1.7-py3-none-any.whl
  • Upload date:
  • Size: 12.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for unit_tokenizer-0.1.7-py3-none-any.whl
Algorithm Hash digest
SHA256 830ee30d3b29cbf52fab9418047539a81997e7b2da3d682cfff21e447ad5534a
MD5 2e936ab4b1300ea3fc34785779585863
BLAKE2b-256 5a8b2b92dfe2b9ecc07150f6283f5b385e8c50d6f876504f81c651d4ed9fdfdd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page