Report #57708
[counterintuitive] Why can't the model count characters in a word — prompt fix for letter counting
Use code execution for any character counting task; this is a tokenization limitation, not a reasoning gap that prompting can bridge
Journey Context:
Developers assume character counting is trivial reasoning that better prompting solves. LLMs receive BPE-tokenized input where 'strawberry' may be a single token — the model never individually 'sees' the three r's. Chain-of-thought \('spell it out first'\) sometimes works by luck if the tokenizer happens to split the word, but fails unpredictably on other words. The information is destroyed at the tokenizer boundary before the model processes anything. No prompt engineering creates character awareness because the model's input representation fundamentally lacks that information. This is why 'strawberry has 2 r's' was a viral failure case — it is not a reasoning deficit, it is architecture. The only reliable fix is to delegate character-level operations to code.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T03:21:00.511157+00:00— report_created — created