04

Reducing batch size

Batch size is how much work moves from one step to the next at once: features per release, commits per test run, decisions per review, questions per meeting. Shrinking it is the cheapest way to shrink queues — it needs no new people and no new capacity, only a change in how work is handed off. Small batches cut cycle time, smooth flow, speed feedback, lower risk, reduce overhead and raise motivation. The right size is an economic trade-off between the fixed cost of each transaction and the cost of holding work while it waits — and because that trade-off has a flat bottom and its transaction cost can be engineered down, the answer is almost always “smaller than you have now”.

Ten things a bigger batch makes worse

B1B2B3B4B5B6B7B8B9B10
One slider, ten consequences. Every tile is computed from the same batch size; the sparkline shows the whole curve from 1 to 50 with your setting marked. Notice that none of them gets better as batches grow — the only argument for large batches is transaction cost, which we put on the scale in the U-curve below.

Watch a batch move through a pipeline

B1B3B4B6
24 work items flow through Spec → Code → Test → Release. Every stage finishes exactly one item per day, whatever the batch size, so capacity is constant. The only rule: a finished item moves on only when its whole batch is finished. Then add a hidden flaw in the spec that nobody can see until the first Test result comes back.

24 work items · 4 stages · each stage finishes 1 item/day

day 0
Spec0/6 batchedqueue (24)done, waiting for batchCode0/6 batchedqueue (0)done, waiting for batchTest0/6 batchedqueue (0)done, waiting for batchRelease0/6 batchedqueue (0)done, waiting for batchDelivered
● queued / being worked (ringed)◌ finished, held for the rest of its batch● redone because of the spec flaw● delivered
delivered
0/24
WIP now
0
avg 0.0
avg cycle time
21.5 d
5.4× one-piece flow
first Test feedback
day 13
b=1: day 3
first customer value
day 24
b=1: day 4
wasted work
—
turn on the flaw

Items delivered over time

batch of 1batch of 6
05101520010203040dayitems deliverednow

All batch sizes, without the spec flaw

batchcycle time1st test1st deliveryall donewasted
14.0 dday 3day 4day 270
27.5 dday 5day 8day 300
311.0 dday 7day 12day 330
414.5 dday 9day 16day 360
621.5 dday 13day 24day 420
828.5 dday 17day 32day 480
1242.5 dday 25day 48day 600
2484.5 dday 49day 96day 960

Without the flaw, average cycle time is exactly 4b − (b−1)/2 days: every item waits for its batch-mates at each of the 4 stages. Total capacity never changed — only the batch size did.

Try: run batch 1, then batch 12. Cycle time grows ~linearly with batch size (B1); the first Test result arrives on day 2b+1 (B3). Turn on the spec flaw: with batch 1 only 3 items were built on it; with batch 12 every item was specced and half were coded before anyone found out (B4, B6).

The batch-size U-curve

B11B12B13B22
A release has a fixed transaction cost (regression testing, coordination, deploy, the release meeting), which pushes toward big batches. Every finished feature waiting for the release carries holding cost — mostly cost of delay — which pushes toward small ones. The total is a U-curve. Three things to see: the bottom is flat, so you can find the optimum approximately; reducing transaction cost moves the whole curve down and the optimum left; and the hidden costs of large batches move it further left still.

Release economics · team finishes 4 features/week

total costtransaction costholding cost (cost of delay)
within 10% of optimum$0$5k$10k$15k$20k10203040batch size (features per release)cost per weekoptimum ≈ 8.0you
economic batch size
8.0 features
release every 2.0 wk
minimum cost
$8k/wk
your penalty
+8%
$667/wk above optimum
30% off optimum costs
+3.5%
the flat bottom

Transaction cost per week = cost per release × 4/b. Holding cost per week = cost of delay × b/2 (on average half a batch is sitting finished and unreleased). Classic optimum b* = √(2·T·D/H). Try: set automation to 75% and watch the optimum halve — then raise cost of delay (launch is near, B22) and watch it shrink again.

Batch size is a continuous variable. It is not “waterfall vs one-piece flow”. You get most of the benefit by moving from 40 to 10, and the flat bottom means you can move in steps, measure, and move again without precise data.
B22 · Dynamic batch size. Cost of delay is not constant across a project. Near a launch window it rises, so the holding cost of each waiting item rises and the economic batch shrinks: test daily in the last month even if weekly was right in the first.

Slippage and the batch-size death spiral

B8B9
A big project is the only train leaving the station for a long time, so every stakeholder needs their feature on it. The longer it has left to run, the faster scope is added — which makes it run longer. Below a critical size this ends in an exponential slip (B8); above it the project never finishes (B9). Splitting the same scope into smaller releases keeps every one of them below the tipping point.

Remaining work over time

total scope (one big batch)remaining (one big batch)remaining (4 small batches)
02040608001020304050weeksteam-weeksplanactual

Actual vs planned duration (B8)

actualon plan
05010015020406080planned scope (team-weeks)actual weeksnever finishes ≥ 83
planned
40 wk
actual (one batch)
54.5 wk
+36% slip
scope attracted
+14.5 wk
critical size R* = 1/k
83 wk
you are at 48%
4 small batches
42.6 wk
11.9 wk sooner, value ships early

Model: the team burns 1 team-week of scope per week; stakeholders add scope at k × remaining work per week (a far-off release is the only train leaving, so everybody boards it). dR/dt = −1 + kR, so R* = 1/k is a tipping point: below it the project ends late, above it the project never ends. Try: raise planned scope toward R* and watch the slip go from a few percent to infinite — then split it.

Small batches pack capacity precisely

B14
The same backlog — about 78 team-days of work — is cut into items of different sizes and loaded into sprints with a target of 85%. Large items leave gaps you cannot fill and overload sprints you cannot unload.

6 sprints × 10 team-days · loading target 85%

target 85%capacitysprint 1#1#235%sprint 2#365%sprint 3#450%sprint 4#5#675%sprint 5#7#870%sprint 6#945%
items in backlog
21
mean loading
57%
target 85%
sprint-to-sprint spread
40 pts
sprints overloaded
0

Try: push item size above 6 days — sprints swing between half-empty and overloaded no matter how you plan. At 1 day every sprint lands on target, in strict priority order.

Batch content: put cheap, likely failures first

B20
A CI pipeline is a batch of checks that stops at the first failure. The order does not change whether the run fails, but it changes how much you pay to find out. Sorting by cost ÷ probability of failure minimizes expected cost — the same logic applies to sequencing risky experiments in a project.
Or reorder by hand with the arrows. Pipeline stops at the first failing check.

CI pipeline, in run order

  1. End-to-end browser suite45.0 min · fails 10% · runs 100% of the time
    45.0 min
  2. Performance benchmark30.0 min · fails 4% · runs 90% of the time
    27.0 min
  3. Integration tests15.0 min · fails 12% · runs 86% of the time
    13.0 min
  4. Unit tests4.0 min · fails 18% · runs 76% of the time
    3.0 min
  5. Type check1.5 min · fails 15% · runs 62% of the time
    0.9 min
  6. Lint & format0.5 min · fails 8% · runs 53% of the time
    0.3 min

Bright bar = expected minutes actually spent on that check (cost × chance the pipeline gets that far).

expected minutes per run
89.2
best 55.3 · worst 90.4
time to bad news
82.7 min
best order 16.5 min
P(run fails)
51%
same in every order

Batch sizes hiding in software development

B15B16B17B18B19B21
Batches are everywhere once you look: test cycles, releases, budgets, requirements documents, plans, design reviews, meetings, and how long you stay on one type of work. For each, compare the large-batch and small-batch practice, drag the handoff interval, and see what has to be true for the small batch to be economical.
Click either card to jump to it; the slider is log-scaled.

Testing: 12 commits/day arriving

avg 90.0 untested commitsuntested commits accumulated (each drop = one batch handed off) · 30 working days
batch size
180
untested commits
avg wait per item
7.5 d
holding cost / year
$338k
at $15 per item-day
economic if a batch costs ≤
$20k
transaction cost at which this interval is optimal

What makes the small batch possible

  • B19Test automation and CI are the infrastructure that makes a test run nearly free.
  • B12Each run's transaction cost drops from days of QA to cents of compute.
  • B20Order the suite so cheap, likely-to-fail checks run first.
B16 · Transport batches. A production batch may need to be large (one test environment setup, one requirements workshop). The transport batch — what you hand to the next step at once — rarely does. Hand work over as each piece is done.
B15, B17, B19 · Enablers. Small batches need cheap transactions: loose coupling between subsystems, people close enough to talk without a meeting, and infrastructure (CI, test fixtures, deploy pipelines) that makes each handoff nearly free.
B21 · Batch size first. Before buying capacity for a bottleneck, shrink batches. It is cheaper, it lowers queues at every stage, and smoother arrivals often make the “bottleneck” stop looking like one.
  • takeawayShrinking batches is the cheapest way to cut cycle time: capacity stays the same, yet items stop waiting for their batch-mates. In the pipeline, batch 12 makes the average item take 10× longer than batch 1 with the same people.
  • takeawayThe economic batch size balances transaction cost against holding cost. The curve is flat at the bottom, and the hidden costs of big batches push the optimum smaller. The highest-leverage move is to lower transaction cost (automate testing and deploys) so the optimum keeps moving left.
  • takeawayBig batches feed themselves: they slip, attract scope, and slip more. Split them into small, frequent releases, hand work over in small transport batches, and build the coupling, proximity and infrastructure that make small batches cheap.

All 22 principles of reducing batch size

book chapter 5
  1. B1
    The Batch Size Queueing Principle

    Shrinking batches shortens cycle time.

    An item in a batch waits for every other item in that batch to be processed before it moves on, so time in queue grows roughly in proportion to batch size. Halve the batch of features per release and the average feature reaches users about twice as fast — without adding a single engineer.

    ↑ see it in the visualization
  2. B2
    The Batch Size Variability Principle

    Smaller batches make flow smoother and less variable.

    Large batches arrive as lumps that swamp a downstream process and then leave it idle. Many small transfers turn a spiky arrival pattern into a nearly steady stream, which lowers queues at every following stage — e.g. a QA team receiving 3 stories a day instead of 30 every other week.

    ↑ see it in the visualization
  3. B3
    The Batch Size Feedback Principle

    Smaller batches deliver feedback sooner.

    You cannot learn whether work is right until the batch reaches the next step. A pull request of 50 lines is reviewed in an hour; a 5,000-line branch waits days, and every line written meanwhile is built on unverified assumptions.

    ↑ see it in the visualization
  4. B4
    The Batch Size Risk Principle

    Smaller batches lower risk.

    Risk falls because cycle time is shorter (less exposure to change), feedback is faster (errors are caught before they propagate), and a failure affects fewer items. A failed deploy of one change is a quick rollback; a failed quarterly release is a crisis.

    ↑ see it in the visualization
  5. B5
    The Batch Size Overhead Principle

    Smaller batches cut overhead.

    It feels like big batches save overhead, but the overhead of large queues dominates: more status meetings, more re-prioritization, more tracking of stale items, more merge conflicts. Teams that move to small batches routinely find their coordination load goes down, not up.

    ↑ see it in the visualization
  6. B6
    The Batch Size Efficiency Principle

    Large batches lower efficiency.

    Slow feedback means more work is done on top of a mistake before the mistake is found, so rework grows faster than batch size. Engineers also lose context: fixing a bug found the same day is quick; fixing one found three months later means re-learning the code first.

    ↑ see it in the visualization
  7. B7
    The Psychology Principle of Batch Size

    Large batches drain motivation and urgency.

    When the deadline is a year away, a day's slip feels irrelevant and nobody sees the result of their work. Small batches give each person fast, visible results and a near deadline, so effort and ownership rise.

    ↑ see it in the visualization
  8. B8
    The Batch Size Slippage Principle

    Large batches make cost and schedule grow exponentially.

    Long projects have more time for requirements and technology to change, and every change triggers more rework and more delay, which invites more change. That is why a 6-month project slips a few weeks while a 3-year program slips by years.

    ↑ see it in the visualization
  9. B9
    The Batch Size Death Spiral Principle

    Large batches tend to grow even larger.

    A big, slow project is the only train leaving the station, so every stakeholder piles on scope; the extra scope delays it further, which attracts still more scope. Big projects also become too important to cancel, absorbing the best people and starving small ones.

    ↑ see it in the visualization
  10. B10
    The Least Common Denominator Principle of Batch Size

    A whole batch moves only as fast as its worst element.

    If a release bundles 40 changes, the release ships when the slowest or riskiest change is ready — and the most sensitive change sets the review and testing rigor for all of them. The bigger the batch, the more likely it contains a slow or risky outlier.

    ↑ see it in the visualization
  11. B11
    The Principle of Batch Size Economics

    The economic batch size is a U-curve trade-off between transaction cost and holding cost.

    Each batch carries a fixed transaction cost (a release, a test campaign, a review meeting), which favors big batches; every item waiting in a batch carries holding cost (mostly cost of delay), which favors small ones. Their sum is a U-shaped curve with a flat bottom, so batch size is a continuous variable you can tune, and being somewhat off the optimum costs little.

    ↑ see it in the visualization
  12. B12
    The Principle of Low Transaction Costs

    Driving down transaction cost per batch lowers total cost and moves the optimum toward smaller batches.

    The U-curve is not fixed: invest in test automation, one-click deploys or standing review slots, and the transaction cost falls, so the optimal batch shrinks and total cost drops. This is how continuous delivery became economical — not by ignoring transaction costs, but by eliminating them.

    ↑ see it in the visualization
  13. B13
    The Principle of Batch Size Diseconomies

    Reducing batch size saves much more than the simple U-curve predicts.

    The classic U-curve counts only transaction and holding cost; it ignores slower feedback, extra rework, higher risk, overhead and lost motivation, all of which grow with batch size. Add them and the true optimum lies further left — and the first moves down from a huge batch pay off enormously.

    ↑ see it in the visualization
  14. B14
    The Batch Size Packing Principle

    Small batches let you fill capacity more precisely.

    Packing a sprint or a test rig with a few big chunks leaves large unusable gaps — a 5-day item can't fit in 3 free days. Small work packages fill the gaps, so you can run at a chosen utilization instead of being forced over or under it.

    ↑ see it in the visualization
  15. B15
    The Fluidity Principle

    Loose coupling between subsystems enables small batches.

    If modules depend tightly on each other, changing one forces a coordinated big-bang change to many. Stable interfaces, modular architecture and backward-compatible APIs let each team ship small changes independently and in any order.

    ↑ see it in the visualization
  16. B16
    The Principle of Transport Batches

    The transport batch matters more than the production batch.

    A production batch (a setup-heavy operation) may need to stay large, but the transport batch — how much work is handed to the next step at once — can usually be cut to one item. Write the spec as one document if you like, but release it to developers section by section as each is done.

    ↑ see it in the visualization
  17. B17
    The Proximity Principle

    Proximity makes small batches possible.

    When people sit together, the transaction cost of a conversation is nearly zero, so they exchange questions one at a time instead of batching them into a weekly meeting or a long email. Co-location (or always-on chat with overlapping hours) shrinks the batch size of communication.

    ↑ see it in the visualization
  18. B18
    The Run Length Principle

    Shorter run lengths reduce queues.

    Alternating frequently between work types — short runs of each — keeps every type's queue small. A team that spends a whole quarter on features then a quarter on tech debt builds a large backlog of each; interleaving them every week keeps both flowing.

    ↑ see it in the visualization
  19. B19
    The Infrastructure Principle

    Good infrastructure enables small batches.

    Small batches only pay when each transaction is cheap, and infrastructure is what makes it cheap: CI pipelines, automated test suites, feature flags, staging environments, and test fixtures that let a subsystem be verified without the whole product.

    ↑ see it in the visualization
  20. B20
    The Principle of Batch Content

    Sequence first the work that adds the most value for the least cost.

    Within a batch, order matters: run the cheap tests most likely to fail first, and attack the riskiest unknowns early, so the batch reveals bad news at the lowest cost. A five-second lint step should never wait behind a forty-minute integration suite.

    ↑ see it in the visualization
  21. B21
    The Batch Size First Principle

    Cut batch size before you attack bottlenecks.

    Adding capacity at a bottleneck is expensive and slow; reducing batch size is usually cheap and reduces queues everywhere, including at the bottleneck, by smoothing the flow into it. Shrink batches first, then see which bottlenecks still matter.

    ↑ see it in the visualization
  22. B22
    The Principle of Dynamic Batch Size

    Change batch size as the economics change.

    The optimum depends on transaction and holding costs, and both move during a project. As launch nears and cost of delay rises, the holding cost per waiting item goes up, so the right batch size shrinks — e.g. daily test cycles near release instead of weekly ones early on.

    ↑ see it in the visualization