AI Evals in Practice · Chapter 4

After Launch: Experiments, Monitoring and Business Impact

SA
Shivank AgrawalFuture with Shivank

DoubtBot passed its offline evals. Every gate is green. Is the job done? Not even close. Offline evals tell you whether you built the product right. This chapter is about whether you built the right product: piloting with real students, monitoring the live system, and finally answering the question every leader eventually asks: "So what did all this do for the business?"

By the end of this chapter you will be able to…

🧠 Think of it like… an everyday analogy
🌍 Real-world example where you have seen this
🔍 Worked example step by step, with real values
⚠️ Watch out a common mistake
🎯 Interview tip a line you can say in an interview
🚀 Going deeper optional, for the curious
🎮 Try it an interactive demo you can click
▶ Running the code with your OpenAI keypip install openai pydantic numpy and set OPENAI_API_KEY. Three GPT-6 rules the code follows: (1) temperature only together with reasoning_effort="none" (Terra and Luna; never on Astra); (2) tool calling on gpt-6.1-terra uses the Responses API (client.responses.create); (3) JSON replies use Structured Outputs: a Pydantic class + client.chat.completions.parse(..., response_format=MyClass), read from .message.parsed. Examples that call DoubtBot or read data files stand for your own product; real outputs will be worded differently from the samples.

Chapter 4 · After LaunchPilots · A/B checks · monitoring · leading and lagging indicators · actions · business impact

4.1 Experiments and pilots: the last check before release

Where we are now
Qualitative ✓
Quantitative ✓
Experiment / pilot
Deploy
Monitoring
Analytics

Even after offline evals look great, most teams don't go straight to a full release. They first run an experiment or pilot: the product goes live for a small group of real users, and the team measures what actually happens.

Offline (quantitative) evals ask…
"Does the system do what it was designed to do?" They measure product behaviour on test sets.
Experiments and pilots ask…
"Do real users use it the way we intended, and does it drive impact?" They measure business metrics and real usage. They also reveal missing guardrails that never showed up in testing.
✅ Business metrics + guardrails
Not just "does it work?" but "does it help, safely?"
📏 A clear baseline
Numbers mean nothing alone. Compare against a control: the current way (TAs only).
🧹 Clean, analysable data
Logging planned in advance, so conclusions are reliable.
⚠️ Pilots are expensive, so not every change needs oneA pilot is usually the most resource-hungry and slowest step. For low-risk projects (an internal tool, a small UX tweak), teams often go straight from offline evals to release. Save pilots for major launches and key features, which is exactly why they're gated behind offline evals.
🌍 How industry does itThe pattern across mature teams is consistent: offline evals first to check the system behaves correctly, then experiments to see how those improvements translate into real-world results. Model labs put heavy emphasis on experiments to understand not just what changed but why. Teams working on image and video models rely on experiments to confirm real-world performance. E-commerce companies use them to connect offline eval gains to actual shopping behaviour.
🧠 Think of it like…A film's preview screening. The film passed every technical check (offline evals), but the director still shows it to a small audience first to see where they laugh, where they get bored, and whether they'd recommend it. A preview audience isn't the same as the real opening weekend, but it's far closer than the editing room. 🎬
⚠️ Pilot users are not real usersBeta users volunteer, are often more motivated and more forgiving, and know they're being watched. A pilot is the closest proxy to production, not a perfect copy. Don't be surprised if numbers move again after full launch, and keep monitoring (section 4.4).

🧪 Designing the pilot

A/B test
Randomly split users: half get DoubtBot (treatment), half don't (control). The cleanest way to measure cause and effect.
Shadow mode
DoubtBot answers every doubt silently; only TAs' answers reach students. Compare later. Zero risk to users, but you can't measure how students react.
Staged rollout
5% → 25% → 100% of users, watching metrics at each step and rolling back if something breaks.
Beta programme
Volunteers opt in. Easy to run, but volunteers aren't typical users (see above).
🔍 Worked example: DoubtBot's pilot plan
FieldPlan
Control (baseline)Sections that keep TAs only
MethodA/B test, randomised by section (4 sections get DoubtBot, 4 don't)
Why by section, not by student?Students in the same section share answers and screenshots. If students in one section were split, the control group would get "contaminated" by DoubtBot's answers.
Primary metricShare of doubts resolved within 1 hour
GuardrailsEscalation compliance on distress messages = 100% · no privacy incidents · student satisfaction not lower than control
Hypothesis"If we ship DoubtBot, doubts resolved within 1 hour will rise from 31% to ≥ 60%, while all guardrails hold."
Duration4 weeks (covers one mid-term, when doubt volume peaks)

📐 Is the difference real, or just luck?

The pilot ends. DoubtBot sections show 64% of doubts resolved within an hour; TA-only sections show 31%. Obviously real. But many differences are small (say 52% vs 48%), and then you need to check whether it could be random noise. The standard tool for comparing two percentages is the two-proportion z-test.

🔍 Worked example: course completion, DoubtBot vs control

A secondary metric: did more students finish the course? DoubtBot sections: 352 of 500 finished (70.4%). Control: 322 of 500 (64.4%). A 6-point gap. Real?

from statistics import NormalDist
import math

def two_proportion_test(x1, n1, x2, n2):
    p1, p2 = x1 / n1, x2 / n2
    pooled = (x1 + x2) / (n1 + n2)                               # overall rate if there were no difference
    se = math.sqrt(pooled * (1 - pooled) * (1 / n1 + 1 / n2))      # expected noise in the gap
    z = (p1 - p2) / se                                            # how many "noise units" the gap is
    p_value = 2 * (1 - NormalDist().cdf(abs(z)))                  # chance of a gap this big by luck alone
    return round(p1 - p2, 3), round(z, 2), round(p_value, 3)

print(two_proportion_test(352, 500, 322, 500))

Output: (0.06, 2.02, 0.043)

Reading it: the gap is 6 points; that's 2.02 "noise units"; the chance of seeing a gap this large if DoubtBot made no difference is 4.3%. Below the usual 5% cut-off, so the result counts as statistically significant, but only just. Because students in a section influence each other, the true noise is somewhat larger than this simple formula assumes, so treat it as promising, and confirm in the next batch.

🎮 Try it: pilot significance check

Enter successes and group sizes for both groups.

🚀 Going deeper: plan the size before the pilot, not afterTo detect a lift from 62% to 67% completion (Δ = 5 points) with 95% confidence and 80% power, each group needs about (1.96 + 0.84)² × [0.62×0.38 + 0.67×0.33] ÷ 0.05² ≈ 1,430 students. One batch doesn't have that many. Options: run across several batches, or choose a more sensitive primary metric that moves more and faster (like "doubts resolved within 1 hour"), and keep completion as a secondary metric. Choosing a metric that can actually show a result within your pilot is part of good pilot design.

4.2 What can still go wrong in production

The offline evals were great, the pilot passed, DoubtBot is live for every batch. After all that work, what could go wrong? Quite a lot.

😱 Users don't need it
The worst nightmare: it works, but people don't use it. Maybe students prefer asking friends on WhatsApp.
🔀 Eval–production mismatch
If the test set didn't truly reflect real usage, problems appear only now. Real students paste screenshots; the test set had only text.
🆕 New edge cases
Things nobody imagined: a student asks DoubtBot to explain an error message in Tamil; another uploads a 2,000-line file.
🔄 User behaviour changes
Some users try to game the system ("pretend this isn't an assignment…"). Others get more advanced: they move from one-line questions to long, multi-turn tutoring sessions, using a Q&A bot like a conversational tutor.
💡 The honest truthEvals will never be perfect, and things will happen in production. The goal of monitoring and analytics is to catch problems early: keep the product delivering value, keep quality and safety standards, and spot issues before they hurt users or business numbers.

4.3 Evals vs analytics

🧪 Offline evals
When: before launch
Question: are we building the product right?
Does the system perform as intended for its designed use cases?
📈 Analytics
When: after launch, with real users
Question: are we building the right product?
How do real people actually use it, and does it create value?
🧠 Think of it like…Chapter 1 compared evals to exams. Continue the analogy: exams measure ability in a controlled setting; after graduation, a person is judged by job performance, the real impact of their work. Evals are the exams. Analytics is the annual performance review. A topper can still struggle at work. 🎓➡️💼

Same type of product, completely different metrics

Compare two chat products. What would their owners want?

💬 A consumer AI assistant (like ChatGPT)
Goals: everyone subscribes · people spend more time with it · long, engaging conversations · happy users who don't switch to a rival
Metrics: number of subscriptions · average time per user · average turns per conversation (want ↑) · thumbs-up rate, CSAT, sentiment
🛵 A food-delivery support bot
Goals: take workload off the call centre · answer quickly and accurately · customers come back and order again
Metrics: agent hours saved · average turns per conversation (want ↓) · task success rate · repeat-order rate

Two things to notice. First, both are chatbots, yet even the same metric ("turns per conversation") points in opposite directions: for the assistant, long chats mean engagement; for the support bot, long chats mean the customer is struggling. Second, each list is a mix of eval metrics, product metrics and business metrics. So "should we monitor eval metrics or product metrics?" isn't an either/or question. You monitor both, plus business metrics.

🎮 Try it: which layer does each DoubtBot metric belong to?

Eval metric = how the AI behaves. Product metric = how users interact. Business metric = what the organisation cares about.

4.4 What to monitor, and why it's harder for AI

Three layers to watch in production
💼 Business impactTA hours saved · course completion · student NPS
👩‍🎓 Product behaviourresolution rate · escalation rate · sentiment · topics · turns per session
⚙️ System health + eval metricslatency · cost · error rate · tokens · guardrail violations · faithfulness (sampled)
Product and business metrics aren't new ideas. Yet few teams monitor AI products well. Why?
🎲 Non-deterministic
The same input can give different outputs, and users take unpredictable paths. What worked in testing may behave differently in production.
🏷 No ground truth
Offline, you had labelled test sets. In production, nobody labels the answers, and human review at scale is expensive. It starts to look like an unsupervised problem.
🧩 No clear event boundaries
Traditional apps track clicks and page views. AI conversations are free-form: inputs and outputs don't map neatly to predefined events. "Did the student succeed?" isn't a button.

Three questions for every metric

1. What are we measuring?
System health, product behaviour or business impact?
2. When does it show up?
Leading indicators move immediately (escalation rate today). Lagging indicators show the real outcome, later (completion at the end of the course). You need both.
3. What action does it drive?
Alerting, optimisation or insight? A metric without an action is just noise. Decide the action up front, when you design the metric.

Then, for each metric on the shortlist

QuestionOptions
Granularity: what is one data point?Turn (one message) · conversation · session · user · whole system
How is it watched?Real-time stream with alerts · or daily/weekly batch analysis
What if it drops?Immediate rollback · alert someone on call · investigate over the next days
💡 Key lineDefine the action before the metric moves. When escalation rate jumps at 2 am during exam week is not the moment to debate who owns it.

4.5 Case study: monitoring DoubtBot

MetricLayerLevelHow watchedOwnerIf it goes wrong…
Latency p95SystemTurnReal-timeEngAlert if > 8 s for 10 min; check provider status; fall back to smaller model
Error rateSystemTurnReal-timeEngAlert if > 2%; roll back last deploy
Tokens & cost per doubtSystemTurnDailyEngIf +20% week on week: review context size and retrieval count
Privacy violationsEval (rule)TurnReal-time, every replyEng + LegalAny hit: block the reply, page on-call, incident review
Faithfulness, integrityEval (judge)TurnDaily, on a sampleData/evalIf below threshold 2 days running: inspect traces, check index
Escalation rateProductConversationReal-time + dailyPMSpike → check retrieval and new topics; TA staffing heads-up
Thumbs-down & sentimentProductTurn / sessionDailyPM + UXRead the worst 20 conversations; add to taxonomy
Topic distributionProductConversationWeeklyPM + instructorInsight: which lectures confuse students?
TA hours saved, completion, NPSBusinessSystemWeekly / per batchHead of learningReview in monthly business meeting

🎯 Judging a sample of live traffic

Running an LLM judge on every production reply is usually a waste. Even with a cheap judge, costs add up with volume, and you don't need every reply judged to know the rate. Sample intelligently instead: a random slice for an unbiased estimate, plus all "suspicious" replies (thumbs-down, very long, escalated).

🔍 Worked example: a nightly sampled-judge job
import random

def nightly_quality_check(todays_traces, judge, rate=0.05):
    random_part = [t for t in todays_traces if random.random() < rate]          # unbiased 5% slice
    flagged = [t for t in todays_traces if t["thumbs_down"] or t["escalated"]]   # look at ALL of these

    fails = sum(judge(INTEGRITY, Verdict, question=t["question"], reply=t["answer"])["verdict"] == "FAIL"
                for t in random_part)
    rate_est = fails / max(len(random_part), 1)                # estimate from the RANDOM slice only
    if rate_est > 0.02:
        alert(f"Integrity failures ~{rate_est:.1%} today (threshold 2%)")
    queue_for_ta_review(flagged)                               # humans read the flagged ones
    return len(random_part), fails, round(rate_est, 3), len(flagged)

print(nightly_quality_check(traces_2026_11_12, judge))

Output: (214, 3, 0.014, 61)

214 replies judged out of ~4,300, 3 integrity failures, an estimated rate of 1.4% (below the 2% alert line), and 61 flagged conversations sent to TAs. Why estimate only from the random slice? The flagged ones are, by design, more likely to be bad; mixing them in would inflate the rate.

🔍 Worked example: what does sampled judging cost?

DoubtBot handles about 4,300 doubts a day. Judging 5% plus flagged ones ≈ 280 judge calls a day. Each call ≈ 1,500 input tokens and 100 output tokens. With gpt-6-luna at about $0.10 per million input and $0.50 per million output tokens:

StepCalculationResult
Input tokens / day280 × 1,500420,000
Output tokens / day280 × 10028,000
Daily cost0.42 × $0.10 + 0.028 × $0.50≈ $0.06
Judging 100% instead× ~15≈ $0.85 / day for each metric

Cheap either way for DoubtBot's volume. But for a product with millions of conversations a day and five judge metrics, sampling is the difference between a rounding error and a real budget line. The goal is not to evaluate everything; it's to evaluate smartly.

🔮 Leading → lagging: watch the signals that predict outcomes

Business outcomes like retention show up late: by the time completion drops, the batch is over. So link each lagging outcome to leading indicators that move earlier:

Early signals and the outcomes they predict
📉 Conversation depth dropsfewer back-and-forth turns
predicts
Lower engagement → lower retention
📈 Escalation rate rises
predicts
Higher TA workload, slower replies
😟 Sentiment falls
predicts
Fewer weekly active users, lower CSAT
🔁 Same doubt asked repeatedly
predicts
Students stuck → lower test scores
Don't wait for the outcome; watch the signals that predict it.
⚠️ "Turns per session" is a DoubtBot trapFor DoubtBot, more turns can be good (a student working through a problem with hints) or bad (a student going in circles, not getting help). Pair it with resolution and sentiment before reading anything into it. A metric's direction depends on the product, as section 4.3 showed.

🚨 Incident simulator

🎮 Try it: DoubtBot's live dashboard

Inject an incident and watch which metrics move first. Leading indicators react within hours; lagging ones take weeks.

4.6 Every metric needs an action

Design metrics by beginning with the end in mind: what will we do when this number moves? Every metric falls into one of three kinds:

🚨 Alert metrics
Need immediate attention: mitigation, or even rollback. Monitored in real time with alerting.
Privacy violations, error rate, latency spikes.
🔧 Optimisation metrics
Help tune the system over time: improve quality, cut cost, adjust behaviour.
Faithfulness, cost per doubt, escalation rate.
💡 Insight metrics
Analytical: reveal patterns and unmet needs, and feed the product roadmap.
Topic distribution, repeated doubts, drop-off points.
Evals, monitoring and analytics as one continuous loop
Problem & idea
Plan & developevals give fast feedback
Releaseevals act as the gate
Production
Real-time monitoringhow it behaves right now+Batch analyticsaudits and deeper insights
feedback: new test cases, updated taxonomy, better coverage
Back into evals for the next version 🔁
Not a one-time process: each stage improves the next. That's how you go from building AI to building reliable AI products.
🌍 What feeding back looks like for DoubtBotAnalytics shows 9% of doubts in week 7 mention "two pointers", a topic missing from the golden test set. The team adds 40 two-pointer cases (from real, anonymised doubts), the next prompt change is tested against them, and the error taxonomy gets a new category: "Confuses two-pointer with sliding window". Production made the evals better.

4.7 From evals to business impact

Your eval metrics are green, the pilot passed, monitoring is in place. Then leadership asks: "So what does all this mean for the business? What's the ROI of this AI investment?" Many teams stumble here. Not because their evals were wrong, but because they stopped one layer too early.

📌 The translation gapEvals describe how your AI system behaves. The business cares about revenue, cost, risk and retention. These are two different languages, and nobody will translate for you. Given how many enterprise AI projects struggle to show measurable returns, you should expect this question, and prepare for it from day one.
The eval → product → impact stack
Layer 3 · Business metricswhat it means for the organisation
TA hours saved per week · course completion rate · student NPS · cost per resolved doubt ❓ almost always missing
Layer 2 · Product metricshow users interact
Resolution rate · escalation rate · sentiment · engagement depth ⏳ some teams reach this
Layer 1 · Eval metricswhat the AI is doing
Faithfulness · integrity compliance · escalation accuracy · latency ✅ most teams are fluent here
Leadership looks at layer 3. Most teams stop at layer 1 or 2.

Three practical moves to close the gap

1. Pick a north star first
Before designing the eval suite, choose one or two business metrics: "what does success look like in 90 days?" Then work backwards: which product behaviours move that number, and which eval dimensions predict those behaviours?
2. Track all three layers together
Not three dashboards owned by three teams. Put them side by side; it's the only way to see if an eval improvement actually moved the needle.
3. Tell the full story at release
When you ship, report all three layers, even if business impact isn't clear yet. Build the habit early and buy-in follows.
🔍 Worked example: DoubtBot's ROI story for the leadership review
  1. Volume: 1,000 students × ~3 doubts a week = 3,000 doubts/week.
  2. Layer 2: resolution without escalation = 65% → 1,950 doubts a week handled fully by DoubtBot.
  3. Layer 3, time: a TA spends ~8 minutes per routine doubt → 1,950 × 8 ÷ 60 ≈ 260 TA-hours saved per week.
  4. Layer 3, cost of the bot: each doubt ≈ 2,500 input + 400 output tokens on gpt-6.1-terra (about $1 / $5 per million tokens): 3,000 × (2,500 × $1 + 400 × $5) ÷ 1,000,000 ≈ $13.5 a week, plus a few dollars of judge sampling.
  5. Layer 1 → 3 link: the weeks when faithfulness dipped (the campus-wiki incident) were the weeks escalations rose and TA hours saved fell by 70. That's the evidence that eval quality drives business value.

"DoubtBot saves ~260 TA-hours a week for under $20 of model cost, with zero privacy incidents. Students get answers in minutes instead of 6 hours, and completion in DoubtBot sections was 6 points higher in the pilot." That's a sentence leadership understands.

🎮 Try it: ROI calculator
TA-hours saved / week
Value of time saved / week
Model cost / week
Return per ₹1 spent on the model

Model cost assumes gpt-6.1-terra at about $1 / $5 per million input / output tokens, converted at ₹88 per dollar (illustrative).

🎯 Interview tip"I design evals backwards from a business north star. For each release I report three layers together (eval metrics, product metrics and business metrics) so leadership can see how a change in, say, faithfulness shows up in escalation rate and then in TA hours saved."

4.8 Summary

✅ Key takeaways

📝 Quick quiz (click to reveal the answer)

Q1. When can you skip a pilot?For low-risk changes, such as internal tools or small tweaks, where offline evals give enough confidence. Pilots are reserved for major launches and key features because they're slow and expensive.
Q2. Why randomise DoubtBot's pilot by section rather than by student?Students in the same section share answers. Splitting one section would let DoubtBot's help leak into the control group, shrinking the measured difference. Randomising whole sections avoids that contamination.
Q3. Treatment 58/100, control 50/100. Is the difference significant?Pooled rate 0.54; SE = √(0.54 × 0.46 × 0.02) ≈ 0.0705; z = 0.08 ÷ 0.0705 ≈ 1.13; p ≈ 0.26. Not significant: an 8-point gap could easily be luck with groups this small.
Q4. Evals vs analytics in one line each.Evals: are we building the product right (before launch, on test sets)? Analytics: are we building the right product (after launch, with real users)?
Q5. Why is "turns per conversation" a tricky metric?Its meaning depends on the product: more turns is good for an engagement assistant, bad for a support bot, and ambiguous for a tutor. Pair it with resolution and sentiment.
Q6. Give the three reasons monitoring AI products is harder than normal software.Non-deterministic outputs and unpredictable user paths; no ground-truth labels in production; free-form interactions without clean event boundaries.
Q7. Why estimate the failure rate from the random sample and not from flagged conversations?Flagged conversations (thumbs-down, escalated) are more likely to be bad by design. Including them would overstate the true rate. Flagged ones go to human review instead.
Q8. Give one leading indicator and the lagging outcome it predicts, for DoubtBot.Rising escalation rate → higher TA workload; falling conversation depth → lower retention; falling sentiment → lower weekly active users or CSAT.
Q9. Name the three kinds of metric by action.Alert metrics (immediate action, real-time), optimisation metrics (tuning over time) and insight metrics (patterns and roadmap).
Q10. What is the "translation gap", and what are the three moves to close it?The gap between eval outputs (how the AI behaves) and business outcomes (revenue, cost, risk, retention). Close it by picking a business north star first and working backwards, tracking eval, product and business metrics together, and including business impact in every release narrative.

📖 Glossary

TermMeaning in one line
Pilot / experimentA limited real-world launch to measure impact before full release.
Control / treatmentThe group without the change / the group with it.
A/B testRandomly splitting users between control and treatment to measure cause and effect.
Shadow modeThe AI runs silently in parallel; users only see the old system.
Staged rolloutReleasing to a growing share of users, with rollback at each stage.
p-valueChance of seeing a difference this large if there were really no effect.
Statistically significantUnlikely to be luck (commonly p < 0.05).
AnalyticsMeasuring real users' behaviour and impact after launch.
Leading / lagging indicatorAn early signal / the later real outcome it predicts.
GranularityWhat one data point is: turn, conversation, session, user or system.
Alert / optimisation / insight metricMetrics grouped by the action they drive.
North star metricThe one or two business outcomes everything else serves.
Translation gapThe distance between eval results and business outcomes.
ROIReturn on investment: value created ÷ cost.