ProjekinAja. Software Engineering Stage 6 · Judgment Lesson 6.6
● Stage 6 · Lesson 6.6

Estimation, Scope, and Saying No

Estimates are distributions, not dates — why software is late, what slicing fixes, and how to communicate risk to people who want a number.

⏱ ~25 min read 📊 Probabilistic ⚙ Interactive widget

🎯 By the end you'll understand

Why the planning fallacy is structural, not a character flaw. How to represent an estimate as a range and why the sum of best guesses had an 8% chance all along. What vertical slicing and walking skeletons do to variance — and when they don't help. How to use scope as the only lever that's honest under uncertainty. The political failure mode (committing to the optimistic date under pressure) named and rehearsed. And how to run a Monte Carlo over a TraceLab feature plan to show stakeholders the actual odds.

KEY INSIGHTA date is a single point on a distribution you haven't shown anyone

When a manager asks "when will it be done?" and an engineer answers "Friday," both parties are pretending a distribution is a scalar. The meeting ends. The distribution doesn't.

Every estimate is a probability distribution over completion time. The number you write on a sticky note is one percentile of that distribution — usually the optimistic median, sometimes the best case — dressed up as certainty for social convenience. Pretending otherwise doesn't collapse the distribution. It just hides it until delivery day.

🔑 Hold onto this

Software schedules fail for two compounding reasons. First, each task is estimated at its expected case, not its 80th-percentile case — so the plan is systematically optimistic by construction. Second, tasks have fat right tails: most finish near the estimate, but a few take 3–10× longer, and because tasks are sequential, one fat-tailed blocker serializes everything after it. The solution is not better point estimates. It is making the distribution visible — so the project can be structured to reduce variance (slicing), scoped to what's achievable in the distribution's plausible range, and communicated honestly when the tail is long.

CORE CONCEPTThe planning fallacy: why engineers aren't bad at estimating

Daniel Kahneman and Amos Tversky named the planning fallacy in 1979: people systematically underestimate the time, cost, and risk of future actions while overestimating the benefits. It is not stupidity. It is a predictable bias with a structural cause.

Two mechanisms drive it in software engineering specifically:

1

Inside-view reasoning

You estimate by imagining the happy path: the implementation you have in mind, the dependencies that cooperate, the reviews that go smoothly. You are reasoning about this specific project from the inside, not about the reference class of similar projects. Reference-class forecasting — "how long did the last three features like this actually take?" — is almost always more accurate, and almost never done.

2

Conjunctive probability collapse

A plan with ten sequential steps, each 90% likely to go right, completes as planned with 0.910 ≈ 35% probability. The estimate implicitly assumed 100% for each step. Nobody multiplied the probabilities. This is the arithmetic version of why "it's just X plus Y plus Z" is always late: "just" composes probabilities multiplicatively, not additively.

💡 The 12% problem

Suppose a five-task project has best-case estimates of 2, 3, 1, 4, and 2 days. The plan says "12 days." Now suppose each estimate is right only 50% of the time (it could easily take longer). The probability that all five finish at or under their best case: 0.55 = 3%. If you're generous and say each has a 65% chance of finishing on or under the estimate: 0.655 ≈ 12%. The "plan" has an 88% chance of slipping before anything has gone wrong. This is structural, not bad luck.

The reference-class cure is uncomfortable but effective. Before estimating, ask: "How long did the last three features of roughly this size take us?" Adjust for what's different. If the answer is "we don't track that," the first investment is tracking it — which is also what TraceLab does.

CORE CONCEPTEstimates as ranges: optimistic, likely, pessimistic

The minimal honest estimate for a task is a three-point estimate: an optimistic time O (things go smoothly), a most-likely time M, and a pessimistic time P (the plausible bad case — not the catastrophic case, but the "this happened last quarter" case). These three numbers implicitly define a distribution.

📖 PERT-style expected value

The Program Evaluation and Review Technique (PERT), developed for the US Navy's Polaris missile program in the 1950s, uses a weighted average: E = (O + 4M + P) / 6. The standard deviation is approximately σ = (P − O) / 6. These assume a beta distribution over [O, P]; the formula is a decent approximation without requiring a full distributional fit. The key insight is that P dominates: a very long tail pulls the mean right even if M is close to O.

For a single task, the expected value is a reasonable planning number. For a sum of tasks, the distribution of the total widens faster than most engineers intuit. If each task has independent variance, the total variance is the sum of individual variances — but the total standard deviation is the root of that sum, which grows much more slowly than the mean. The result: a schedule of ten tasks each with σ = 1 day has a total σ ≈ 3.2 days, not 10 days. That sounds reassuring. It isn't, because task durations are not independent, and the worst case isn't Gaussian — it's fat-tailed.

The problem with Gaussian thinking about schedules: real task completion times are right-skewed. A task cannot finish before zero effort, but it can take arbitrarily long. A blocked dependency, an undiscovered design constraint, an external API that changed its schema — these inject mass into the right tail that a normal distribution does not represent. This is why a Monte Carlo simulation over empirically-shaped per-task distributions gives a more honest picture than PERT arithmetic: it propagates the tail.

PERT / normal approximation mean = mode real task duration (right-skewed) mode mean (pulled right) fat tail
PERT treats task duration as symmetric around the mean. Real tasks are right-skewed: a blocked dependency or hidden complexity injects mass into the tail that symmetric models miss. Monte Carlo captures this; PERT arithmetic does not.

SEE ITMonte Carlo schedule simulator

Below is a TraceLab feature — "structured query API for fleet telemetry" — broken into slices. Each slice has an optimistic and pessimistic estimate in days. Adjust them, then run 1,000 simulated futures. The histogram shows the distribution of completion dates. Notice what happens when you re-slice the fat-tailed task into two smaller ones: the distribution tightens visibly.

⚙ Interactive · Monte Carlo schedule simulator

Adjust optimistic / pessimistic estimates per slice, then run. 1,000 deterministic simulations using a seeded LCG — same seed, same result every time. Each simulation samples uniformly over [O, P] per slice then sums.

p10 (optimistic)
—
p50 (median)
—
p80 (safe commit)
—
p95 (planning buffer)
—
Best-case sum
—
Chance ≤ best-case
—

Click "Run 1,000 simulations" to see the delivery distribution. Then re-slice the fat-tailed task and run again — watch the p95 move.

Two things the simulation reveals that verbal reasoning misses. First: the p50 is always later than the best-case sum — because at least one task almost always takes longer than its optimistic estimate. The meeting where "we just sum the estimates" implicitly assumes the p10 scenario for each task simultaneously, which compounds to a very small probability. Second: re-slicing moves the distribution left and tightens it — not by doing less work, but by converting one uncertain task with a long tail into two tasks with shorter tails each. Variance reduction is a design decision, not an estimating one.

IN PRACTICEVertical slicing and walking skeletons

The canonical failure of a phased plan: each phase feels safe to commit to in isolation, but slippage in phase 1 serializes every downstream phase. The mitigation is not adding buffer (though that helps) — it's restructuring work so that each unit of work is independently valuable and deployable, even if incomplete. That is the logic of vertical slicing.

A vertical slice cuts across all layers of the system to deliver one thin but complete user story. For TraceLab's query API: instead of "first build the parser, then the execution engine, then the HTTP layer, then the UI," a vertical slice is "one query type, one result format, working end-to-end, deployed to staging." It is slower to start, faster to correct course.

📖 Walking skeleton

A walking skeleton (Alistair Cockburn, early 2000s) is the thinnest possible vertical slice that exercises every architectural joint — not to deliver user value, but to prove the joints connect. For TraceLab: a skeleton might be one HTTP endpoint, one SQL query, one result returned as JSON, one test asserting end-to-end behavior. The skeleton walks (all layers present and connected) before you add flesh (the full feature set).

Why does this reduce variance? Because architectural surprises — "the query planner we assumed would work, doesn't" — are discovered in sprint 1 instead of sprint 5. Those surprises are the fat-tailed events. Moving them forward in time doesn't eliminate them; it prevents them from serializing the rest of the plan.

⚠ When slicing doesn't help

Vertical slicing reduces schedule variance for discovery-heavy work. It does not help when the work is genuinely sequential by nature (you cannot build the second floor before the first), when the team is too small to parallelize, or when the risk is external (a vendor dependency, a regulatory approval). In those cases the right tool is explicit contingency allocation — carving the budget for the uncertain item separately and communicating that it is a risk, not a plan.

horizontal / layered plan (common, risky) Phase 1: Parser (complete) Phase 2: Execution Engine (complete) Phase 3: HTTP layer Phase 4: UI phase 2 slip serializes phases 3 and 4 vertical slice plan (recommended) Parser Engine HTTP UI Slice 1 Slice 2 Slice 3 each slice ships; slip in slice 2 leaves slice 1 done
Horizontal slicing defers integration until the end — where all surprises land simultaneously. Vertical slicing delivers a thin, working column per sprint and discovers architectural surprises early when they are still cheap.

CORE CONCEPTScope is the only honest lever

When a deadline is fixed and the estimate distribution says delivery is likely later, you have three levers: time (ask for more), resources (add people), or scope (do less). In a real schedule discussion, time is often not negotiable. Resources are seductive but frequently counterproductive — Brook's Law (The Mythical Man-Month, 1975) says that adding people to a late project makes it later, because of onboarding and communication overhead. Scope is the lever that senior engineers reach for first, and the one junior engineers are most reluctant to touch because it feels like admitting defeat.

It is not defeat. It is honesty about the distribution. "The p50 delivery date for full scope is week 9. If we cut the advanced filter syntax to v2, the p50 moves to week 5 and the p80 to week 6." That is a scope conversation. The stakeholder can decide; you have given them the information to decide with. Hiding the distribution and committing to week 5 for full scope is the political failure mode — and it destroys trust the day it slips.

🔑 The "MVP isn't cutting corners" reframe

A minimum viable feature is not a degraded version of the real feature. It is the thinnest slice that delivers real value so that learning starts. Early delivery means early feedback, which means the scope that gets built in v2 is scope you know users need, not scope you assumed they needed. Scope cuts are not apologies. They are engineering decisions based on risk-weighted value.

The practical move: for any project, write a scope ladder before you start — a list of features in value order, with cumulative estimate ranges. When the schedule pressure arrives (and it will), you have already done the hard thinking about what's cuttable. You are not improvising a negotiation under pressure; you are reading from a document you wrote when you were calm.

LeverCommon beliefRealityWhen it actually works
Add peopleMore hands = done soonerBrook's Law: onboarding + comms overhead often net-negative short termParallelizable work, well-isolated tasks, ramp-up time available
Ask for more timeUnprofessional; PM won't allow itLegitimate if distribution warrants it; only dishonest if you knew at commitment timeExternal deadline is soft; risk is genuinely high
Cut scopeAdmitting failureEngineering decision; preserves quality and trust; creates negotiation roomAlmost always — the scope ladder turns this from a crisis into a conversation
Crunch (overtime)Shows commitmentDegrades code quality, increases bugs, causes attrition; net schedule loss beyond a few daysOne-time, short, with recovery time built in — rarely

IN PRACTICESaying "I don't know yet" professionally

The hardest moment in engineering is this: a stakeholder asks "when will it be done?" and you genuinely do not know yet — because the work is exploratory, because a dependency is uncertain, or because you haven't had time to estimate properly. The tempting answers are "two weeks" (a made-up number that feels responsible) or "I don't know" (accurate but unhelpful). Neither builds trust.

The professional answer has three parts:

1

State what you know and what you don't

"I have a p50 estimate of X days once we resolve the dependency on Y. The uncertainty is currently driven by Z. Until we spike on Z, any date I give you is noise."

2

Offer a time-boxed exploration

"Give me two days to spike on Z. After that I will have a real estimate range, and I will book another meeting to walk through it." This is not delay — it is buying information to make the estimate credible.

3

Make the commitment format explicit

When you do give a range, name the percentile: "p50 is week 5, p80 is week 7, anything earlier than week 4 would require cutting the reporting module." Now the conversation is about risk tolerance, not about whether you are a reliable person.

⚠ The political failure mode

The most common bad outcome: a stakeholder expresses disappointment at p80 = week 7 and asks if you can "stretch" to week 5. Under social pressure, the engineer agrees. The distribution has not changed. The engineer has now made a commitment they knew was the p20 case — a 20% chance of success — while both parties pretend it's a plan. When it slips (80% chance), the stakeholder concludes the engineer is unreliable. The engineer learns that honesty costs them credibility. The whole loop is a trust-destruction machine. Breaking it requires naming it explicitly: "I can commit to week 5, but I want to be clear that puts us at roughly the 20th percentile of my estimate. I'm comfortable with that risk if you are — I just want us to both know it's a stretch, not a plan."

The engineer who consistently names the distribution and hits their p80 dates builds more trust than the one who consistently commits to p20 dates and slips. This takes a few cycles to establish, but it is the asymptotically dominant strategy.

TRACELABTraceLab v5: scoping the fleet-scale query API

TraceLab v5 ships at fleet scale — 10,000 robots generating telemetry, a structured query API replacing the original grep-and-CSV loop that v0 was born with. The scoping conversation looks like this:

scope-ladder-v5-query-api.mdpre-meeting artifact
# TraceLab v5 · Query API — scope ladder
# Written before schedule discussion. Values are rough; ranges shown.
# "Cut line" to be decided in the meeting, not here.

SLICE 1 — walking skeleton  [O: 2d  P: 5d]
  # One metric type, one time-range filter, REST endpoint,
  # integration test. No UI. All architectural joints proven.

SLICE 2 — core filter set    [O: 3d  P: 8d]
  # robot_id, time range, metric name. Paginated. Enough for dashboards.

SLICE 3 — aggregations       [O: 4d  P: 12d]  ← fat tail: query planner unknown
  # sum/avg/p99 per robot, per episode. Needs planner spike first.

SLICE 4 — advanced filter syntax  [O: 3d  P: 6d]
  # expression filters, label selectors. Defer to v5.1 if needed.

SLICE 5 — UI query builder   [O: 2d  P: 5d]
  # Optional. Can ship without; CLI covers p80 of users.

# Cumulative p50 (slices 1-5): ~19d  |  p80: ~26d
# If we cut slices 4-5: p50 ~14d  |  p80 ~19d
# Slice 3 is the variance driver. Spike it first (2d) to tighten range.

This artifact does three things before the meeting starts. It surfaces Slice 3 as the fat-tailed risk — not after the project starts but before commitment. It offers a pre-computed scope cut (drop slices 4 and 5) with a concrete schedule improvement. And it proposes a spike (2 days) that converts an 8-day pessimistic range on Slice 3 to something tighter. The meeting now has information to make a decision, not just pressure to agree to a date.

The debt ledger thread: the original TraceLab v0 find_run function scanned the CSV on every call — O(n) per lookup, which became O(n²) across a workflow. At 10,000 robots, that debt compounds from a nuisance to a hard blocker. Slice 2's pagination is the direct payment: a properly indexed store with cursor-based pagination replaces the full-scan path. The debt from Lesson 1.1 finally closes here.

WEAKNESSWhere this bites

✗ Mistaking the p50 for a commitment

Giving a median estimate as a delivery date means you have a 50% chance of missing it — by construction. Most engineers communicate estimates as medians and are surprised when they slip half the time. The p80 is a better commitment date: "80% likely we're done by then" is a reasonable professional standard. If the p80 is unacceptable to stakeholders, that is a scope conversation, not a reason to misrepresent the p50 as a commitment.

✗ One fat-tailed task dominates every schedule

Engineers building a 5-task schedule often think about the average — "each task is around a week, so five weeks." But if one task has P = 4 weeks and the rest have P = 2 weeks, that one task alone can push the whole project to the right when it hits its pessimistic case. The discipline is to identify the fat-tailed task first, spike it or re-slice it before committing to the full schedule. The Monte Carlo makes this visible: a single wide-distribution task inflates the p80 far more than its expected value suggests.

✗ Using estimation theater as a planning substitute

Planning poker, t-shirt sizing, and story points are useful for getting a team to surface different mental models of a task. They are not useful as the output of a planning process — because they produce relative orderings, not absolute time ranges, and they give stakeholders no way to reason about delivery dates. Using "8 points" as a schedule artifact while refusing to convert to time ranges is a way of performing estimation without doing it. At some point, someone has to translate to calendar time, and that translation is where the real work of estimation happens.

KEY INSIGHTHow this connects

  • TraceLab v0 (1.1) — the fat-tailed debt (full CSV scan, string concatenation) introduced here is the variance driver in the v5 query API slice plan. Naming the debt at origin makes the schedule conversation five stages later far simpler.
  • Version control (2.x) — a scope ladder that is not in version control is a document that gets "updated" in the hallway. Treating scope artifacts as first-class repo items makes scope decisions auditable.
  • Capacity planning (6.2) — the same probabilistic thinking applies: a system "planned" to 90% utilization has the same failure mode as a schedule planned to p10. The mental model transfers directly.
  • ← Previous: Technical Debt and Legacy (6.5) — the debt ledger we built there directly shapes which slices are fat-tailed here; debt is the main source of pessimistic-case blowout.
  • → Next: Engineering in the Age of AI (6.7) — estimation in the presence of AI agents adds a new wrinkle: the agent's variance is often higher than a human's for novel tasks, and the tail events (agent goes in a wrong direction and produces plausible-looking garbage) are a new category of schedule risk.

Estimation is not a pre-project ritual. It is a continuous conversation between what you know and what the distribution says. As work proceeds and unknowns resolve, estimates should narrow. If they are not narrowing, the right response is to name that openly — and to ask what spike would buy the most information per day invested.

GLOSSARYKey terms introduced

Planning fallacy
The systematic tendency to underestimate time and cost while overestimating benefits, driven by inside-view reasoning and conjunctive probability collapse. Named by Kahneman and Tversky (1979).
Three-point estimate
An estimate expressed as optimistic (O), most likely (M), and pessimistic (P) values, implicitly defining a distribution. PERT uses E = (O + 4M + P) / 6 as the expected value.
Monte Carlo simulation
A technique that runs many simulations (each sampling from task duration distributions) to produce a distribution of outcomes — here, project completion dates — rather than a single point estimate.
Vertical slice
A unit of work that cuts through all architectural layers to deliver one thin but complete capability, enabling early deployment and early discovery of integration risks.
Walking skeleton
The thinnest possible vertical slice that exercises every architectural joint — not to deliver user value, but to prove the layers connect before flesh is added.
Scope ladder
A pre-meeting artifact listing features in value order with cumulative estimate ranges, enabling principled scope negotiation under time pressure.
Brook's Law
Fred Brooks's observation (The Mythical Man-Month, 1975) that adding people to a late software project makes it later — because onboarding and communication overhead temporarily reduce velocity.
Reference-class forecasting
Estimating a task by examining the historical distribution of similar tasks rather than by reasoning about the specific task from scratch. Consistently more accurate than inside-view estimation.

ACTIVE RECALLCheck your understanding

Answer in your own words first, then reveal.

1If a 5-task project has best-case estimates summing to 10 days, and each task has a 70% chance of finishing at or under its estimate, what is the probability the project finishes on or before day 10?›

0.75 ≈ 17%. The "best-case sum" plan is actually the roughly-17th-percentile plan. This is why plans built from best-case estimates slip most of the time — not because engineers are bad at estimating, but because conjunctive probabilities compound multiplicatively. A p50 plan would give the project a 50% chance of on-time delivery, which means committing to the p80 date is the professional standard for reliable promises.

2What does "re-slicing a fat-tailed task" actually do to the schedule distribution, and why?›

Re-slicing converts one task with a wide [O, P] range into two tasks with narrower ranges each. Because total variance is the sum of individual variances, and each smaller slice has lower variance than the original single task, the total variance decreases. The distribution tightens — not because the work gets done faster, but because smaller tasks have fewer ways to blow up. A 1-week task might have P = 4 weeks; two half-week tasks might each have P = 2 weeks, giving a combined P = 4 weeks only in the worst case for both simultaneously, which is less likely.

3A stakeholder asks you to commit to a date that you calculate is the p20 of your estimate distribution. What do you do?›

Name the percentile explicitly: "That date is achievable but puts us at roughly the 20th percentile of my estimate — meaning there's an 80% chance we miss it. I can commit to it if you want to accept that risk, but I want us both to know it's a stretch, not a plan." Then offer scope options: "If we cut feature X, I can get the p80 down to that date." This keeps the conversation factual and gives the stakeholder real choices. Agreeing silently to a p20 date under pressure is the failure mode that destroys trust over time.

4Why is scope the "honest lever" while adding people often isn't?›

Scope cuts directly reduce the work to be done, with a near-immediate effect on the estimate distribution. Adding people helps only when work is genuinely parallelizable and the team has capacity to onboard newcomers — Brook's Law says that for most late-stage additions, onboarding cost and communication overhead cause a temporary net slowdown before any benefit arrives. Asking for more time is honest but often constrained. Scope is the lever that senior engineers prefer because it is honest about the distribution, keeps quality intact, and creates the negotiation room to deliver something valuable by the date, rather than something complete by a later date.

Next: what changes when the agent writing the code isn't human →