When Is AI Not the Answer?
When a fixed rule, an exact sum or a person beats an AI model, and how to say so, explained simply for your AI interview.
In short
AI is not the right tool when the answer must be exact and repeatable, when a simple rule already solves the problem, or when a wrong answer costs more than the time saved. Use plain code for those jobs, and use AI only for the messy part, with checks around it.
11 min readIntermediateCommon · estimateFacts checked 27 November 2026
Say it out loud
Read it once, then say it without looking. Start with the short one; use the long one when they ask you to go deeper.
I start by asking whether AI is needed at all. If the rule is fixed, like a tax table or a refund cap, plain code is cheaper, faster and easy to test. If the answer must be exact, or a wrong answer would cost a customer real money, I keep the model out of the decision. I use AI for the messy part, like reading a letter or sorting emails, and a person or a check approves what it produces.
The first question I ask is whether a model is needed at all. Anthropic's advice for builders is to find the simplest solution possible and add complexity only when it is needed. That can mean not building an agent at all.
AI is a poor fit in three cases. First, when the rule is fixed, like a fee table or a leave policy. Code applies it exactly, every time, and you can test it. Second, when the answer must be exact, like a payout total, because a model can guess a number and sound sure. Third, when a mistake costs more than the time saved and nobody reviews each output.
Where AI does help is the messy part: reading a doctor's letter, sorting emails, drafting a reply. In a claims flow I let code check the policy first, let the model summarise the letter, and have an adjuster approve every payment. The model never sets the amount.
The trade-off is real. An agent costs more and takes longer, and its errors can compound over many steps. So I pick the smallest system that works, and I say that out loud. For many tasks, one well-prompted model call with the right documents attached is enough, and it is far easier to test.
When is AI not the answer, in plain words?
A language model reads messy text, sorts things and drafts words well. A calculator, a rulebook or a database does exact work better. Saying AI is not the answer means picking the tool that fits the job, and the simplest one that works is usually the best.
A heuristic is a rule of thumb that a person writes by hand, such as a refund limit of 50 dollars that needs no approval. Plain code runs it the same way every time.
Think of a hospital pharmacy. The dose for a child is worked out from a fixed rule based on weight, and the pharmacist checks it against the prescription. Nobody asks a chatbot to work the dose out from memory. AI belongs where no table exists, such as a handwritten note from a ward nurse.
Key words
- Heuristic
- A rule of thumb written by hand, run as code.
- Deterministic
- Same input, same output, every time.
- Hallucination
- A confident answer from a model that is wrong.
- Latency
- How long the user waits before the answer appears.
When is plain code the better tool?
Use plain code when the rule is written down and the answer must be exact. Code is deterministic: the same input gives the same output, so it can be tested with fixed inputs. A model may word or number its answer differently on a second run, which makes it harder to test.
- Fixed rule
Refund limits, leave days, tax tables
Write the rule once in code. Change it in one place, and tests check it.
- Exact sum
Interest, payouts, fee totals
A model can add the wrong figure and still sound sure. Code adds it the same way every time.
- Clear lookup
Account status, branch hours
Read the database. A model only repeats what it reads, and adds risk on the way.
Here is a made-up bank's late-fee rule in plain Python. No AI is involved, and a fee with no rule goes to a person instead of being guessed.
# A bank's late-fee rule. Plain code, no AI: the same input always gives the same answer.
FEES = {"late_card_payment": 25, "late_loan_payment": 40}
def fee_for(kind):
if kind not in FEES:
return "NO RULE: send to a person" # never guess a fee
return "Fee: " + str(FEES[kind]) + " dollars"
print(fee_for("late_card_payment"))
print(fee_for("late_loan_payment"))
print(fee_for("late_gift_card_payment"))Output
Fee: 25 dollars Fee: 40 dollars NO RULE: send to a person
Pick the simplest tool that fits
A new request
what the team wants done
Fixed rule or exact sum?
same input, same answer
Plain code
Rules run in code
tested and repeatable
AI with checks
Model reads messy text
drafts or sorts only
Same answer each time
easy to test
A person checks
before anything counts
Answer goes out
logged for audit
- 1The team sorts each request first.
- 2Yes: a fixed rule or an exact sum is handled in code.
- 3No: the input is messy, so AI can help with the reading.
- 4Code gives the same result every time.
- 5The model's draft goes to a person before it counts.
- 6A repeatable result goes out.
- 7An approved draft goes out.
“When building applications with LLMs, we recommend finding the simplest solution possible, and only increasing complexity when needed. This might mean not building agentic systems at all.”
Anthropic
“Don't be afraid to launch a product without machine learning.”
Google
Google's machine learning guide makes the same point with a rule of thumb: if machine learning might double a result, a simple heuristic may already deliver half of that gain. Start with the rule, and add learning only where it pays.
Why can't a model be trusted with exact answers?
A model writes the words that most likely come next. It can give a wrong figure in the same calm tone as a right one, and nothing in the sentence warns you. That is why code should own the numbers, and the model should only explain them.
OpenAI's research on hallucinations argues that standard training and testing reward guessing over admitting uncertainty, so models are pushed to guess rather than say "I don't know".
“Strategically guessing when uncertain improves accuracy but increases errors and hallucinations.”
OpenAI
“Remember, although these techniques significantly reduce hallucinations, they don't eliminate them entirely.”
Anthropic docs
Anthropic's guide on reducing hallucinations suggests three habits: let the model admit uncertainty, ground answers in quoted text, and check each claim with a citation. Running the same prompt several times and comparing the outputs can also reveal a problem, because inconsistent outputs may signal hallucinations.
Tip
Asked how you would handle exact answers? Say the sum or the rule runs in code, and the model only explains the result in words.
What do speed and cost trade-offs look like in a real case?
Anthropic notes that agentic systems (AI that plans its own steps and uses tools) often trade latency and cost for better task performance. An agent that loops through many steps multiplies the wait and the bill. Its errors also compound, because one wrong step feeds the next.
Anthropic's guidance is that workflows (steps your code runs in a set order, with the model at certain steps) offer predictability and consistency for well-defined tasks. Agents suit open-ended problems where the number of steps is hard to predict. For many applications, optimizing a single model call with retrieval (looking up the right documents first) and examples is usually enough.
Here is a made-up insurance claims flow that uses all three parts: code, AI and a person. Each part does the job it is good at.
A claims flow that splits the work
Claim arrives
form, photos, a doctor's letter
Policy check in code
cover, dates, limit
AI summary of letter
drafts, never decides
Adjuster approves
a person signs off every payout
Payment or refusal
logged for audit
- 1Code checks the form, dates and cover first.
- 2Claims that pass the policy check go on to the letter reader.
- 3The model's summary goes to a person.
- 4The adjuster signs off, then payment or refusal follows.
Even for its coding agents, Anthropic says human review is still needed to make sure solutions fit the wider system's requirements. That agents guide is from December 2024. Its own note says much of its tooling has changed since, and points to Anthropic's newer Managed Agents guidance, so check that before you quote the tooling.
How would you decide whether to add AI to a claims team?
Ask three questions: what does a wrong answer cost, how fast must it be, and who checks it? If the output is a payout amount, code sets the number and a person approves it. The model can summarise the letter, which saves time without deciding the pay.
- Without a check
The model pays
It reads the letter, guesses a figure, and the payout goes out. One bad guess costs real money.
- With a check
Code and a person decide
Code sets the limit, the model drafts the summary, and an adjuster approves. Most errors get caught before money moves.
What does the interviewer want to hear?
A strong answer covers
- A clear test: is the rule fixed, is the answer exact, and what does a wrong answer cost?
- Plain code for fixed rules, sums and lookups, because it can be tested.
- AI for messy text, with checks in code and a person for the final call.
- Honesty about cost and speed: each model call adds delay and spend.
- The simplest version first, then added complexity only when it helps.
- A real example from your own work, with the trade-off you chose.
Common traps
Trap"Every problem can be solved with AI."
BetterOnly the messy part needs AI. Fixed rules and sums belong in code, which you can test.
Trap"A bigger model will be more accurate, so use it."
BetterA bigger model can still guess with confidence. Add checks and let it say it does not know.
Trap"Agents handle anything open-ended, so build one."
BetterAgents add cost and compounding errors. Use the simplest fix first, such as one model call with retrieval, or a fixed workflow for well-defined tasks. Use an agent only where the steps cannot be fixed in advance.
Can you spot the wrong tool?
Spot the right split
A bank's assistant is asked for the late fee on a card payment. Which reply shows the right split?
Quick check
A team wants AI to work out a claim payout from the policy limits. What is the best advice?
Can you answer these from memory?
Flash cards · tap a card to flip it
What will they ask next?
Learn it in depth
Last updated on 27 November 2026
Deciding whether a process needs AI at all?
I design and build AI products and agents, including the plain code and the checks around them. Book a short call and tell me which step you are unsure about.