Categories: None [Edit]

ruby_llm-tokenizer

https://rubygems.org/gems/ruby_llm-tokenizer
https://github.com/washu/ruby_llm-tokenizer
Pure-Ruby facade over Hugging Face `tokenizers`, OpenAI `tiktoken_ruby`, and SentencePiece bindings that maps ruby_llm model identifiers (gpt-4o, llama-3, mistral, ...) to the correct tokenizer and exposes a small API for counting, analyzing, and truncating text against a model's context window. Includes an opt-in approximation backend for models with no published tokenizer (Claude).

Total

Ranking: 189,418 of 195,762
Downloads: 788

Daily

Ranking: 102,761 of 195,747
Downloads: 1

Depended by

RankDownloadsName
195,425226ruby_llm-toolbox

Depends on

RankDownloadsName
2,7737,040,533tiktoken_ruby
5,1211,549,348tokenizers
166,6903,085sentencepiece

Owners

#GravatarHandle
1iconwashu214