Home / Guides / How AI reads numbers
AIHow AI reads numbers
An AI model can explain calculus and then slip on 152222 × 7. Here's why — and how to get reliable numbers out of AI.
Step 1: numbers become tokens
Language models don't read characters; they read tokens, chunks of text from a fixed vocabulary. How numbers get chunked depends on the tokenizer. Some popular tokenizers group digits into runs of up to three, so 152222 might become 152 | 222. Others, such as the original LLaMA models, split every number into single digits. A model that sees 152 | 222 has to learn that the second chunk is worth hundreds while the first is worth hundreds of thousands — positional value is something it must infer, not something it's given.
Step 2: the model predicts, it doesn't calculate
A language model produces the most plausible next token. For familiar facts (7 × 8 = 56) that works because the answer appears countless times in training text. For a fresh multiplication of two six-digit numbers, there is no memorised answer; the model must carry digits across chunk boundaries in its head, so to speak, and small errors creep in. Famous slips — like a model insisting 9.11 is larger than 9.9, perhaps because it reads them like version numbers — come from text patterns overriding arithmetic.
Step 3: the fix is tools
Modern assistants increasingly hand arithmetic to a calculator or run code, then report the result. That's the same approach this site uses: every number on 152222 Number Lab is computed by deterministic code in your browser, never "predicted".
Tips for using AI with numbers
- Ask the assistant to use code or a calculator for any arithmetic that matters.
- Ask it to show working — errors become visible.
- For money, tax or dosage, verify independently.
- Give numbers in a consistent format (1,52,222 vs 152,222 can confuse both people and models).
- Use AI for what it's great at — explaining, structuring, drafting — and tools for exact results.
Numbers and AI in business
Retailers use machine-learning models to set prices (often still ending in 9), banks use them to flag unusual transactions, and auditors combine models with statistical tests like Benford's law. In all of these, the model's job is pattern-finding; the arithmetic underneath is ordinary computation.
Try it yourself: put any number into the decoder and compare with your favourite chatbot.