Open this lesson in your favourite AI. It'll walk you through the why, explain the demo, and quiz you on the try-it list.
Every automation project starts with a huge win. The first 60% of a task automates in a weekend and saves you five hours a week — the ROI is obvious. Then the next 20% takes a month and it still handles most cases, and you feel great. But the last 20% — the weird formats, the exception cases, the once-a-quarter escalations — never stops eating engineering time and never stops surprising you with bad outputs. The 'last 20%' cost curve says the marginal cost of covering more cases rises faster than the marginal value they generate, which means for most personal automations there's an optimal incomplete solution. The whole rest of this course is designed around this: build the 80% that pays for itself, and route the last 20% back to a human (you) with as much context as the bot can pre-assemble. If you don't internalize this, you'll either give up when the exception cases eat your Sunday, or worse, keep grinding and end up with an unmaintainable pile of one-off patches.
A rough model of automation ROI as a function of coverage: hours saved go linearly with coverage, but hours spent maintaining exception logic scale super-linearly. There's a peak, and it's rarely at 100%.
Use these three in order. Each builds on the one before.
In one paragraph, explain why an automation that handles 80% of cases can be more valuable than one that handles 100%.
Walk me through the specific reasons the last 20% of edge cases cost more to automate than the first 80% — file formats, model failure modes, and exception recovery cost.
I'm going to automate spam deletion. I can hit 98% accuracy easily, but the last 2% (false positives) delete real emails. What's my design instead of chasing 100%?
# ROI = hours_saved - hours_spent_maintaining. Coverage above ~80% costs more than it saves.
def hours_saved(coverage_pct, hours_per_week_task):
return coverage_pct / 100 * hours_per_week_task
def hours_maintaining(coverage_pct):
# Empirical shape: linear up to 60%, then quadratic (exception logic dominates).
base = coverage_pct * 0.05
if coverage_pct <= 60:
return base
over = coverage_pct - 60
return base + (over ** 2) * 0.012
def net_roi(coverage_pct, hours_per_week_task):
return hours_saved(coverage_pct, hours_per_week_task) - hours_maintaining(coverage_pct)
# For a 5h/week task, plot ROI across coverage
task_hours = 5.0
for pct in range(30, 105, 10):
saved = hours_saved(pct, task_hours)
maint = hours_maintaining(pct)
net = net_roi(pct, task_hours)
print(f"coverage={pct:3d}% saved={saved:5.2f}h/wk maint={maint:5.2f}h/wk net={net:+5.2f}")
# Where's the peak?
best = max(range(30, 100), key=lambda p: net_roi(p, task_hours))
print(f"\nPeak ROI coverage: {best}%")
python3 main.py