tiktoken
Measure the same UTF-8 prompt text with two tiktoken encodings and separate text-only counts from full API usage.
Sources checked: Nov 12, 2026
Official website ↗Measure the same UTF-8 prompt text with two tiktoken encodings and separate text-only counts from full API usage.
Related reading

Count Tokens in Multilingual Prompts Before Sending Them
Measure the same UTF-8 prompt text with two tiktoken encodings and separate text-only counts from full API usage.