tokenmeter-core 0.1.0

Token counts of text in o200k_base, with the text split into token groups on grapheme boundaries
Documentation
# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
rust-version = "1.99"
name = "tokenmeter-core"
version = "0.1.0"
authors = ["Alexey Simonenko <alexey@simonenko.dev>"]
build = "build.rs"
include = [
    "src/**/*.rs",
    "build.rs",
    "data/*",
    "Cargo.toml",
    "LICENSE",
]
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Token counts of text in o200k_base, with the text split into token groups on grapheme boundaries"
readme = false
keywords = [
    "tokenizer",
    "tiktoken",
    "bpe",
    "openai",
    "tokens",
]
categories = ["text-processing"]
license = "MIT"
repository = "https://github.com/meritt/tokenmeter.rs"

[lib]
name = "tokenmeter_core"
path = "src/lib.rs"

[dependencies.rustc-hash]
version = "2.1.3"

[dependencies.tiktoken-rs]
version = "0.12.1"
default-features = false

[dependencies.unicode-segmentation]
version = "1.13.3"

[build-dependencies.base64]
version = "0.23.1"

[build-dependencies.sha2]
version = "0.11.1"

[lints.clippy]
cast_possible_truncation = "allow"
missing_errors_doc = "allow"
missing_panics_doc = "allow"
module_name_repetitions = "allow"
undocumented_unsafe_blocks = "warn"

[lints.clippy.pedantic]
level = "warn"
priority = -1

[lints.rust]
missing_debug_implementations = "warn"
unsafe_code = "deny"
unsafe_op_in_unsafe_fn = "deny"