Skip to main content

Usage Sample ''''''''''''

.. code:: python

    from xtokenizer import Tokenizer

    tokenizer = Tokenizer.from_texts(texts, min_freq=5)
    sent = 'I love you'
    tokens = tokenizer.encode(sent, max_length=6)
    # [101, 66, 88, 99, 102, 0]
    sent = tokenizer.decode(tokens)
    # ['<BOS>', 'I', 'love', 'you', '<EOS>', '<PAD>']

Metadata

Release files for xtokenizer 0.0.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for xtokenizer 0.0.6
File Size Uploaded Provenance Actions
xtokenizer-0.0.6.tar.gz 18.9 kB Without provenance Details for xtokenizer-0.0.6.tar.gz

Release files / xtokenizer-0.0.6.tar.gz

Download URL xtokenizer-0.0.6.tar.gz
Size 18.9 kB
Tags Source
SHA-256 checksum
How to use checksums
719e028ce65cb17fdce8a843d41820e8f04d167457c160f0dc8f8fd3a139e7f2
BLAKE2b-256 checksum
How to use checksums
132094505706b015ae89398220b24bf720e0b665d754ff19bcb7609bd2fb7b84
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.18

Security for xtokenizer 0.0.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page