Researcher Completes Exact Claude Tokenizer Reproduction
ctok tool now matches Claude output for natural languages and programming languages.
TLDR
Sander Land announced that ctok now exactly reproduces token counts from Claude's tokenizer. The match holds across 500+ natural languages and 22 programming languages for both tokenizer families. Vocabulary estimates for Claude 4.7+ dropped to 15k entries. The tool runs offline without API calls. Posts from other researchers and engineers on X note the small vocabulary size and discuss possible links to softmax computation, while some question whether code comments in the project were AI-generated.
Combined views
359.4K
19 Sources, first seen 48d ago