Pebellslearn by building
0%
RoadmapsMatrixCoursesSandboxSign in
Generation  ›  Lesson

Generating in Small Slices

2. Generation 12 minGenerate an app in thin end-to-end slices, starting with a walking skeleton and replacing fakes one at a time, with a check and a save point after each.

Generating in Small Slices

Asha pasted her whole brief and asked for everything at once. Ten minutes later she had forty new files, a screen that mostly worked and an allergy filter that did nothing. She could not tell which of the forty files was wrong, and every fix she asked for broke something else.

The rule

Generate one thin working slice, check it, save it, then the next.

A slice is a thin piece of the product that runs end to end — through screen, logic and data — even if it does very little. The first slice is often a walking skeleton: the whole path exists, with a fake answer where the hard part will eventually go.

Why slices beat one giant request:

  • Checkable. A small change has only a few places where it can go wrong.
  • Recoverable. A save point after each working slice — a commit in version control, or your tool's snapshot — means a bad next step costs minutes, not the project.
  • Honest. Each slice is checked against its own acceptance check, so broken parts cannot hide inside a big result that only looks finished.

Put the riskiest parts early, and make sure each slice leaves the app working.

The shortcut

Skeleton first, then swap fakes for real, one at a time. List the slices, and after each one: run it, check it, save it.

Pantry Pal in five slicesStep 1 of 5
  1. Slice 1: the walking skeleton

    Type items, tap Suggest, see three cards. The server returns three hard-coded dinners. Run, check, save.

If slice 3 goes wrong, Asha returns to the save point after slice 2 and asks again, more precisely. Nothing that already worked is at risk.

A tempting alternative is building layer by layer: all the screens first, then all the server code, then the database. It feels organised, but nothing runs end to end until the very end, so the first real test happens when everything is already built. Slices cut across the layers so that every step can be run and checked.

Drills

Answer fast — trust the rule.

quick drill

What makes something a slice?

quick drill

What is a walking skeleton?

quick drill

Slice 4 breaks the suggestion screen. What is the cheapest recovery?

quick drill

Why does one giant "build everything" request make bugs harder to fix?

Remember

  • Generate one thin working slice, check it, save it, then the next.
  • Skeleton first, then swap fakes for real, one at a time.
  • Trap: one giant request with no save points, impressive in minutes and untraceable for days.

Practice — level up

0/1 solved

Write your answer, then compare it with a rubric and a model answer.

ExplainPlan the slices

Plan the first four slices for an AI app that turns a photo of a handwritten shopping list into a typed list. Say what the walking skeleton fakes, which slice replaces the fake, and explain why you save after every slice.