tiktokenx 0.1.0

A high-performance Rust implementation of OpenAI's tiktoken library
Documentation
[package]
name = "tiktokenx"
version = "0.1.0"
edition = "2024"
authors = ["Umesh Yadav <git@umesh.dev>"]
description = "A high-performance Rust implementation of OpenAI's tiktoken library"
license = "MIT"
repository = "https://github.com/imumesh18/tiktokenx"
homepage = "https://github.com/imumesh18/tiktokenx"
documentation = "https://docs.rs/tiktokenx"
readme = "README.md"
keywords = ["tokenizer", "bpe", "openai", "gpt", "nlp"]
categories = ["text-processing", "algorithms"]
rust-version = "1.85.0"
exclude = [
    ".github/",
    "scripts/",
    "target/",
]

[lib]
name = "tiktokenx"
crate-type = ["lib"]

[dependencies]
# Core dependencies - using only widely-adopted, well-maintained crates
regex = "1.10"
# For downloading vocabulary files
reqwest = { version = "0.12", features = ["blocking"], optional = true }
# For base64 decoding of tiktoken files
base64 = "0.22"
# For hash verification
sha2 = { version = "0.10", optional = true }
# For serialization support
serde = { version = "1.0", features = ["derive"], optional = true }

[dev-dependencies]
criterion = { version = "0.7", features = ["html_reports"] }
tokio-test = "0.4"
# For memory profiling
peak_alloc = "0.3"

[[bench]]
name = "encoding_benchmark"
harness = false

[features]
default = ["download"]
# Optional features for additional functionality
serde_support = ["serde"]
# Enable downloading vocabulary files at runtime
download = ["reqwest", "sha2"]