Organic, Artisanal Math
Why we let AI write code but keep it miles away from the calculator — and why deterministic arithmetic matters for your prime.
There’s an undeniable craze in technology right now: slap “AI-powered” onto a product and watch the hype machine roar. AI toothbrushes. AI toaster ovens. AI-generated pizza recipes that confidently advise mixing non-toxic school glue into the tomato sauce so the mozzarella doesn’t slide off.
So when people discover that we turn names into certified, mathematically proven prime numbers, a natural question pops up:
“Do you use AI for that?”
Let’s be completely candid: AI coding agents helped write the code for this website. We’re human developers and mathematicians, but hand-crafting thousands of lines of responsive CSS and TypeScript boilerplate in the modern era is an unnecessary exercise in suffering.
However, when it comes to finding, encoding, and mathematically verifying your prime number?
We keep AI as far away from the calculator as humanly possible.
There is a strict, non-negotiable firewall in our engine: AI never touches the arithmetic. Here’s why.
The Dictionary Problem
Asking a large language model whether a number is prime is like asking an English dictionary whether a suspension bridge can support a forty-ton semi-truck. Dictionaries are brilliant at words; bridges require structural physics.
Large language models (LLMs) operate by predicting the most statistically plausible next token in a sequence. They have ingested vast oceans of text about mathematics, which allows them to sound remarkably confident. But language models do not calculate — they confabulate. They string together answers that look syntactically pleasing based on statistical patterns in their training data.
Try it yourself right now. Open your favorite chatbot and ask: is 91 prime?
More often than not, it will cheerfully reply: “Yes! 91 is a prime number because it cannot be evenly divided by any positive integer other than 1 and 91.”
Except it isn’t. 91 = 7 × 13.
The model didn’t actually check for factors. It simply recognized that “91” is an odd two-digit number ending in 1, doesn’t end in 5, and frequently appears in math forums near words like “prime.” It performed vibes-based arithmetic.
Your personalized prime number deserves better than vibes.
Why Neural Networks Struggle with Numbers
To understand why chatbots stumble over elementary arithmetic, look at how they see text.
When you type a number like 43,112,609, a transformer model doesn’t see distinct digits with place values. It chops the text into arbitrary subword tokens. One token might be 43, the next ,11, and the last 2609.
Imagine trying to perform multi-digit long division, but your brain is only allowed to look at random syllables of the numbers and guess the next syllable based on essays you read three years ago. It’s a minor miracle chatbots can do simple addition at all!
Neural networks are stochastic (probabilistic) machines. If you ask an LLM to compose a sonnet about a toaster, a 98% probability distribution yields delightful, creative poetry. But in number theory, a 99.99% probability of primality is just a polite synonym for wrong.
What We Actually Use
Instead of feeding your name into a probabilistic black box and hoping the neural weights feel lucky today, our backend runs on classical, deterministic number theory:
- Exact Huffman Encoding: We compress your name into compact binary using an exact prefix tree. Every character maps to an unambiguous bit sequence.
- Reversible Feistel Permutation: We shuffle the bits using classical symmetric cryptography. With your 3-character unlock key, the math unwinds in reverse down to the exact bit.
- The Miller–Rabin Primality Test: When verifying candidate primes, we don’t ask an AI to guess. We use the Miller–Rabin algorithm running 16 independent rounds of modular exponentiation with carefully chosen prime bases.
Here is how the two approaches compare:
| Feature | AI Chatbot | Our Math Engine |
|---|---|---|
| Core Method | Probabilistic next-token prediction | Modular exponentiation & number theory |
| Confidence | ”Looks right based on internet vibes” | Mathematically provable certainty |
| Can Hallucinate? | Regularly (especially on tricky composites like 91) | Never (0% chance) |
| Data Representation | Fragmented text tokens | Arbitrary-precision exact integers (BigInt) |
| Auditable? | Trillions of opaque neural weights | Fully transparent, reproducible code |
If a composite number were somehow to sneak past all 16 rounds of our Miller–Rabin verification, the probability would be less than 1 in 416 — that’s 1 in 4,294,967,296. For the 128-bit numbers we test, the specific bases we choose make the test effectively deterministic: zero false positives.
(Curious about the mechanics of those 16 rounds? We explore them in detail in The Miller–Rabin Test.)
A Brief History of Machines That Can’t Do Math
To be fair to the robots, computers have always had a slightly rocky relationship with arithmetic — even the non-AI kind:
- The Pentium FDIV Bug (1994): Intel’s flagship Pentium processor shipped with a missing lookup table entry in its floating-point unit. In rare cases, long division returned errors after a few decimal places. It cost Intel $475 million to replace the processors.
- Excel’s 65,535 Bug (2007): For a brief period, multiplying certain numbers in Microsoft Excel (like
=77.1*850) displayed100,000or65,535instead of the correct answer. The world’s most popular spreadsheet temporarily forgot how to multiply. - Floating-Point Shenanigans: Open your web browser’s developer console right now, type
0.1 + 0.2, and press Enter. You’ll get0.30000000000000004. Standard IEEE 754 binary floating-point representation cannot represent decimal tenths cleanly.
Because standard numbers get rounded, truncated, or coerced, our backend avoids standard floating-point variables entirely. We use arbitrary-precision integer arithmetic (BigInt), ensuring every single digit of your 39-digit prime is preserved with absolute mathematical precision.
Why “Organic” Isn’t Just Marketing
When we say “100% organic, artisanal math,” we’re poking fun at artisanal buzzwords — but the underlying philosophy is real:
- No Machine Learning in the Math. The algorithm doesn’t learn, adapt, or update parameters. It follows fixed mathematical laws proven decades ago by Gary Miller and Michael Rabin. It gives the exact same result today, tomorrow, and in ten thousand years.
- No Black Boxes. Every step of the pipeline — from character normalization to bitwise permutation and primality testing — is completely auditable. You could verify your prime by hand with enough paper, pencil lead, and coffee.
- No Training Data. Our prime finder has never read the internet. It doesn’t know what social media thinks about primes. It only knows modular arithmetic, and modulo arithmetic doesn’t have opinions.
The Hallucination-Free Guarantee
When you claim your prime from A Prime for You, your certificate doesn’t come with a disclaimer. It doesn’t say “Generated with 97% confidence based on training data.”
It is a genuine mathematical prime: indivisible, eternal, and verified by pure deterministic logic.
We love modern AI tools for helping us build websites and debug CSS. But when it comes to your prime number? We leave the math to the timeless laws of arithmetic.
The “From Name to Prime & Back” Series
Follow the complete journey of how a name transforms into a prime number and back:
- First, We Tidy Your Name — Standardizing characters, accents, and spaces.
- Packing Your Name Into Fewer Bits — How Huffman compression makes the puzzle fit.
- Your Tiny Key and the Number Lock — Feistel ciphers and why 3-character keys are fun.
- Prime Hunting With Tiny Tweaks — Wiggling nonces and the Miller–Rabin primality test.
- How Decoding Works (Backwards Magic) — Running the pipeline in reverse to recover your name.
- Share the Prime, Protect the Key — Keeping your name private until you choose to reveal it.
Companion Deep Dives:
- Huffman Coding: Squeezing Names into Fewer Bits — The mathematics of optimal binary prefix trees.
- The Miller–Rabin Test — How we verify primality in microseconds without trial division.
- Organic, Artisanal Math — (You are here) Why deterministic algorithms beat AI hallucinations.