All posts
Jun 15, 2026AI

Don't Build Critical Logic on a Guess

LLMs guess the next word. That is fine for drafts, risky for invoices, loan math, and anything that must be exact every time.

If you are bringing AI into a product, hallucination is not a bug you prompt-engineer away. It is built into how LLMs work. They predict the next token. For many prompts there are several valid continuations.

Words like table or chair have a small set of reasonable options. Numbers do not. The price of a chair could be almost anything, so the model picks one that sounds plausible. That is why salary figures, EMI math, and billing totals need deterministic code behind them, not a longer system prompt.

Prompt engineering helps with tone and structure. It does not make an LLM reliable for business-critical numbers. The fix is architecture: use AI where fuzzy is OK, and use code, schemas, and validation everywhere else.

That is how I built EMI Analyzer. AI reads messy payslip text. FOIR and eligibility math run in plain TypeScript. Same inputs, same outputs, every time.

news
new: ~/labs live · income tax calculator with slab-by-slab breakdown for FY 2025-26 · new: automate.adharshr.in is live · get a free automation roadmap · projects now show terminal README on hover · automate.adharshr.in audit wizard · get a free automation roadmap in 5 steps · open to collab · reach out via ~/contact · new: ~/labs live · income tax calculator with slab-by-slab breakdown for FY 2025-26 · new: automate.adharshr.in is live · get a free automation roadmap · projects now show terminal README on hover · automate.adharshr.in audit wizard · get a free automation roadmap in 5 steps · open to collab · reach out via ~/contact