AI engineering philosophies: evals first, the simplest thing that works, the model will change
Three beliefs shape how good AI engineers build: measure before you claim, climb the ladder of techniques one rung at a time, and assume the model under your feature will be replaced. Each has a price, and you should know it before you adopt it
After three complaints that an assistant's replies sound stiff, an engineer edits the system prompt, tries five conversations by hand and finds the replies friendlier. What is the main risk in shipping that edit?
Every AI team has a philosophy, whether or not anyone wrote it down. Some teams inherited theirs from a viral post, some from a vendor’s quick-start guide, some from the last bad week. It shows in small habits: whether a prompt change gets a test run, whether the first answer to a quality problem is a bigger model or a clearer instruction, whether anyone knows which model version the feature runs on.
This chapter sets out the three beliefs that most good AI engineering teams share, what each one assumes, what it costs and where it fails. The aim is practical. By the end you should be able to write a one-page statement of how you build, with a price against each principle, and defend it to a colleague who holds a different view.
Why this work needs its own philosophy
A conventional function returns the same output for the same input. You write a test, it passes, and it keeps passing until someone changes the code. A model-backed feature breaks both halves of that. The same input can produce different outputs. The behaviour can also change when nothing in your code has changed, because the model under it was replaced or because the mix of inputs shifted. The AI engineering course builds each technique in detail; this chapter is about the habits that decide which technique you reach for and when.
Three beliefs follow from that difference.
| Belief | The question it answers | What it costs |
|---|---|---|
| Evals first | How do we know the feature is good, and that a change made it better? | Days of up-front work, and the time of the people whose judgement defines “good” |
| The simplest thing that works | Which technique should we use? | Slower feeling progress, and the discipline to keep a rung you find boring |
| The model will change | What do we build so that today’s choices are survivable? | An eval you must keep alive, and some indirection you must not over-build |
They are not independent. The ladder in the second belief is only usable if you have the measurement from the first, and the third is the same measurement run again on a new model.
Evals first
What it says. Before you build or change a model-backed feature, decide how a good output will be recognised. Collect real or realistic inputs, write down what each one should produce or what a correct response must do, and run the feature against them. Hamel Husain’s essay “Your AI Product Needs Evals” (2024) is the practitioner’s argument: the teams that improve fastest are the ones that can see, case by case, what a change did. Anthropic’s documentation on defining success criteria gives the same advice from the vendor’s side: tie each criterion to something you can measure, set targets that are realistic for current models, expect to need several criteria at once, and build evaluations that mirror real traffic, edge cases included.
Why it is right. Output that is sampled cannot be checked by reading a few examples, because the cases you read are the cases you thought of. Without a fixed set, every prompt tweak is a coin toss that feels like progress. With one, a change shows up as a list of cases that got better and a list that got worse, and the second list is usually where the learning is. An eval set is also the only way to compare options fairly. You cannot choose between a longer prompt, retrieval and fine-tuning by arguing; you can choose by running all three on the same cases.
What it costs. Someone has to write the cases and decide what “correct” means. For a task such as brand voice or a support reply, the person who can judge is a domain expert: a writer, a support lead. Their time is the real price, and it is why the eval gets skipped. Plan for it openly. The eval set chapter in the course shows how to build one that is large enough, covers the failure modes and has labels two people agree on, and the LLM-as-judge chapter shows how to automate part of the grading once you have trustworthy human labels to calibrate it against.
Where it fails. Four places.
First, an eval can measure the wrong thing. A set drawn only from easy, typical inputs will score high and say nothing about the cases that cause complaints. Cover failure modes on purpose, as the course chapter describes.
Second, an eval can leak. If the cases you test on are also the examples in your prompt, the examples in a fine-tuning set or the documents you retrieve from, you are marking a pupil on the questions they were taught. The data leakage lesson shows the mechanism; the practical rule is to hold out cases before you use any of the rest for anything.
Third, a score is not a decision. Husain makes the point that an eval’s pass rate is a product decision, not a demand for a hundred per cent as with unit tests. Someone has to say what rate is good enough for this feature, given what a failure costs.
Fourth, evals can become a ritual. A team that runs a suite nobody reads, or a judge nobody has checked against a human, has the cost without the benefit. Read the failing cases yourself, every time.
The simplest thing that works
What it says. Use the least complex technique that meets the bar, and move up only when evidence shows it does not. The Anthropic engineering post “Building effective agents” (Erik S. and Barry Zhang, 2024) puts it plainly: “we recommend finding the simplest solution possible, and only increasing complexity when needed.” It adds that you should consider adding complexity “only when it demonstrably improves outcomes”, and it advises starting with the model API directly, because frameworks can tempt you into complexity a simpler setup would not need. The team behind “What We Learned from a Year of Building with LLMs” (Yan, Bischof, Frye, Husain, Liu and Shankar, 2024) treat fine-tuning in the same spirit: a later step, after simpler approaches have been tried and found short.
The ladder. The techniques sit on a ladder of increasing cost to keep, not increasing worth.
| Rung | What you change | How fast you can change it | What it costs to keep |
|---|---|---|---|
| A clearer prompt | The instructions | Minutes | Almost nothing; needs a regression check |
| Examples in the prompt | A fixed set of good examples | Minutes | Tokens on every call; the examples go stale |
| Retrieval | Context chosen per request | Hours to days | An index, a retriever to measure, a freshness job |
| Fine-tuning | The model’s weights | Days to weeks | Data, training runs, a model tied to one base version |
| Agents and multi-step designs | The control flow | Weeks | More failure modes, more tokens, harder evals |
Read the table top to bottom as a cost curve. A prompt change can be undone in a minute. A fine-tuned model is a build artefact with its own pipeline. The fine-tuning chapter in the course makes the point that fine-tuning is good at teaching form and style and poor at adding facts, and gives the order to try things in. The prompting chapter shows how far a well-written prompt with examples goes before you need anything else.
Why it is right. Each rung adds things that can break and things you must maintain. A team that jumps to fine-tuning or an agent for a problem a prompt would have solved pays for the pipeline for the life of the feature. Complexity also hides the cause of a failure: when a five-stage pipeline gives a bad answer, you have five places to look.
Where it fails. The belief is a rule for where to start, not for where to stop. Teams misuse it in two ways. Some treat “simplest” as “whatever we already know”, and refuse a rung that a measurement has shown they need. The honest test is the eval: if the simple version scores below the bar on the cases that matter, the next rung is justified. Others stop after one try, find the prompt “does not work”, and move up without ever improving the prompt. Give each rung a real attempt, with the same cases, before you leave it.
There is also a cost to staying low that is easy to miss. A prompt with forty examples in it is simple to write and expensive to run, because you pay for those tokens on every request. The prompt cache lesson shows one way the bill shrinks. Sometimes the rung above is cheaper to run.
The model will change
What it says. Assume the model under your feature will be replaced, by you or by the vendor, and design so that this is survivable. Vendors publish deprecation schedules; models are retired and new ones appear with different habits. A prompt tuned on one version, a fine-tuned adapter trained on one base model and a cache laid out for one tokeniser all carry that dependency.
Why it is right. The cost of a migration is dominated by how quickly you can answer one question: is the new model at least as good on our cases? A team with a live eval set answers it in an afternoon. A team without one answers it by anxiety, or by not migrating until the date arrives. The eval from the first belief is the asset that makes this belief affordable. Keep prompts in version control as described in the prompt management chapter, run the set when anything changes, as in the evals in CI chapter, and know how you would choose another model if you had to.
What it costs. An eval you maintain, which means adding a case whenever production shows a new failure. A small amount of indirection: the model name in configuration rather than scattered through the code, a pinned dated version in production, and a note of which behaviours you rely on.
Where it fails. The usual excess is a grand abstraction layer that hides every model behind one interface so that switching is free. It never is. Models differ in how they handle tools, system prompts, long context and refusals, and a lowest-common-denominator wrapper throws away the features that made you choose one. Keep the seam thin, in one place, and prove it by running the eval on a second model once, before you need to.
The other failure is the opposite: building as if today’s limits are permanent. A workaround for a weakness of the current model, such as an elaborate chain of steps to make it follow a format, may become dead weight after an upgrade. Tag such workarounds in the code with the model behaviour they work around, so someone can test whether they are still needed.
Where practitioners disagree
You will meet strong opinions. Each is a reaction to a failure the holder has seen.
“Vibes are enough early on.” Some builders argue that a formal eval is premature when you are still finding out what the product is. They have a point at the very start: a week of exploration before the task is defined is not worth evaluating. The disagreement is about when the line falls. Most teams find it falls earlier than expected, at the first moment someone other than the builder depends on the output.
“Ship and learn from production.” Husain and others advise logging real inputs and outputs and reading them, and that is not at odds with evals first; the log is where new cases come from. The disagreement is whether you can ship without any offline set. For a low-stakes, human-reviewed tool you can. For a feature that acts on its own, such as sending a message or moving money, you should not.
“Fine-tune early, it is the serious option.” Teams with a lot of labelled data and a narrow task do gain from it, and a small tuned model can be cheaper to run than a large general one. The usual caution is that most teams reach for it before they have measured a good prompt, so they cannot tell whether it helped.
“Use a framework.” Frameworks speed up the first demo and can obscure what is sent to the model. Anthropic’s advice is to start with direct API calls. Many teams adopt a framework later, for a specific need, with the eval already in place to show what it changed.
A mature team borrows from all four camps: exploration while the task is unclear, an eval from the moment it matters, the ladder for choosing techniques, and a standing assumption that the model will move.
Putting a price on each principle
A philosophy you cannot afford is a slogan. For each principle you hold, write down what it costs, when you will break it, and what evidence would change your mind. That is the artefact at the end of this chapter, and it is also the best way to disagree productively with someone else’s philosophy: ask what theirs costs.
A few examples of a priced principle:
| Principle | The cost, in plain terms | When you would break it |
|---|---|---|
| No prompt change ships without a run of the eval | About twenty minutes of waiting and reading per change; a day or two to build the set first | An internal draft tool where a person checks every output and a failure is cheap |
| We try the prompt, then examples, then retrieval, before tuning | A month in which the team looks slow to people who want the impressive option | A narrow task with thousands of labelled examples and a measured gap that prompting cannot close |
| The model name lives in one config file and the eval runs on a second model each quarter | A few hours a quarter and a second set of API charges | A prototype with a planned life of weeks |
The “break it” column matters as much as the cost column. A principle with no exceptions has usually never been tested against a deadline.
Day to day
Philosophies show up in routines. At Junior AI Engineer or Software Engineer on an AI team level you will not set the policy, but you will carry it out, and you will notice where it is not being carried out.
Before every change to a prompt, a tool description or a retrieval setting. Run the eval and read the cases that changed, in both directions. Write a line in the change log: what you changed, the before and after, and which cases moved. Five minutes of writing saves the next person an afternoon.
Daily, ten minutes. Read a handful of real outputs from production, not the ones the dashboard flagged. Husain and the “year of building” authors both press this habit. You are looking for failures nobody has a case for yet.
Weekly, with the domain expert. Sit with the person whose judgement defines good, a support lead or a head of copy, and go through the week’s failures and the cases that disagreed with a judge. Add three to five new cases from what you find. This is the meeting that keeps the eval honest, and it is the one most likely to be cancelled.
When you are tempted to move up the ladder. Write down the measurement that says the current rung is not enough, with numbers: “the prompt with examples scores 71% on the 60 held-out captions; the bar is 85%”. If you cannot write the sentence, you are not ready to build the next rung.
Monthly. Check the vendor’s deprecation page for the model you run on, and note the date in the team’s calendar. Re-read your own philosophy statement and ask which line has not been tested against a real decision.
When a new model is released. Run the eval on it the same week, not when a colleague asks. Whether or not you switch, you now have a number and a date.
There is one person building the feature, and the philosophy is whatever that person does under deadline. Keep the whole system small: a prompt in a file, thirty to fifty cases in a spreadsheet, one script that runs them. Do not build a platform. The risk is that the demo works and nobody records why, so when a customer complains you cannot tell whether the last change caused it. Write the cases the day the first customer depends on the output, and keep the model name in one place.
Several teams are building AI features and each has a different habit: one has an eval, one has a spreadsheet of screenshots, one has neither. The work is to turn the best habit into a shared one without a platform team yet. Agree a minimum: a held-out case set per feature, a run before any prompt change, a named owner for the model version. Show the failures that an eval caught, because that evidence persuades teams that a mandate does not.
The philosophy is written into standards, risk reviews and procurement, and the danger is that the standard outlives the technology. A rule that every model change needs a month of review makes sense for a credit decision and none for a drafting aid. Tier the requirements by what a failure costs, keep a central place for approved model versions and deprecation dates, and make the eval evidence part of the review pack, so the conversation is about numbers rather than reassurance.
Template
# How we build: <feature or team>
Owner · Date · Reviewed with: <the person who judges quality>
## What we are building and who judges it
<One sentence on the feature. Name the role whose judgement defines a good output.>
## Principles
| Principle | What we do | What it costs | When we would break it | What would change our mind |
|---|---|---|---|---|
| Evals first | | | | |
| Simplest thing that works | | | | |
| The model will change | | | | |
## The ladder for this feature
Starting rung: <prompt / examples / retrieval / tuning / multi-step>
Bar to meet: <measure and number>
We move up when: <the measurement>
## Model dependency
Model and version: <pinned version>
Retirement date, if published: <date or "check monthly">
How we would test a replacement: <the eval, run on a second model>
## Review
Next review: <date> · Last principle tested against a real decision: <which> WORKED EXAMPLE
Kilnworth is a 60-person agency in Lekki. Its tools group has two engineers. Rufaro owns a call-notes summariser that turns recordings of client calls into action lists for account teams, about 40 calls a week (illustrative). This is Rufaro’s statement for it, after an action list missed a client’s deadline change.
Who judges. The account directors who use the lists. Rufaro needs 90 minutes of two directors’ time to label 30 calls.
| Principle | What we do | What it costs | When we break it | What would change our mind |
|---|---|---|---|---|
| Evals first | 30 hand-checked calls, each with the actions a director expects; every prompt change runs them | One day to build, about 15 minutes per change, 90 minutes of director time | A typo fix in the output heading | Two quarters with no regression caught |
| Simplest thing | Start with one prompt and the transcript in the context; no retrieval of past calls | Lists lack history from earlier calls | Directors ask for history and the eval shows missed items come from missing context | A measured miss rate above 10% that history would fix |
| The model will change | Pinned dated version in one config line; eval re-run on a second model each quarter | About three hours a quarter | A one-month pilot | A vendor notice of retirement, which starts the migration clock |
Where the numbers come from. The costs are Rufaro’s estimates from a trial run of the 30 calls. Reviewed with the two directors; next review at the end of the quarter.
Ladder. Start on a prompt. Bar: at least 27 of 30 calls with no missed deadline. Move up only if the prompt with two worked examples scores below that.
Now you
You are the engineer for Kilnworth’s weekly client email drafter, which turns each client’s campaign spreadsheet into a draft performance email for an account manager to review and send. It drafts 12 emails a week, one per live campaign across Kilnworth’s five clients. Three things happened this month. After the account directors asked for a friendlier tone, you edited the prompt on Tuesday and drafts went out on Thursday without a test run; two of the 12 quoted the previous week’s click figure, and nobody can say whether your edit caused it. You are tempted to add retrieval of each client’s past emails to match their style, which would take about three days. And the vendor has announced that the model version you use will be retired in 90 days. You have 20 past emails that account managers rated good or poor, and no other labelled data. Write your statement of how you build, with a price against each principle.
Self-check
Kilnworth's caption-drafting tool drafts about 150 captions a week across five clients. For Owoleaf it keeps sounding generic: Radek, who leads the copy team, says six in ten Owoleaf drafts are heavily rewritten (illustrative). The agency has 400 approved past Owoleaf captions, and Rufaro has a week. What do you recommend?
- POST Building effective agents Erik S. and Barry Zhang (Anthropic), 2024
The clearest statement of the simplest-thing-that-works belief from a model vendor: start with direct API calls, add complexity only when it demonstrably improves outcomes, and tell workflows from agents.
- POST What We Learned from a Year of Building with LLMs (Part I) Eugene Yan, Bryan Bischof, Charles Frye, Hamel Husain, Jason Liu and Shreya Shankar, 2024
Six practitioners write up tactical lessons from a year of shipping, covering prompting, retrieval and evaluation. Part III, on strategy, cautions against fine-tuning too early.
- POST Your AI Product Needs Evals Hamel Husain, 2024
The practitioner's case for evals first: build a domain-specific set, read the traces, and treat the pass rate as a product decision. Read it before the next time someone proposes shipping on vibes.
- DOC Define success criteria and build evaluations Anthropic
The vendor's guidance on writing measurable criteria and evals that mirror real traffic and include edge cases. A good checklist for the first page of your eval set.
- BOOK AI Engineering: Building Applications with Foundation Models Chip Huyen, 2025
The longest single treatment of how the techniques on the ladder relate and how to evaluate each. Use it as the reference behind the habits in this chapter. Read: The chapters on evaluation and on prompt engineering, RAG and fine-tuning.
All companies and people in these examples are fictional. Any resemblance to a real business or person is unintended.