draft · v0.1.226
💬Comments welcome. To leave a note, select any text and click the note / highlight button that pops up — or open the panel with the tab at the top-right (‹). Notes are visible only inside our private review group.

1.3 How this book was made

This book is, in part, about generative AI, so it should be clear up front that it was also written with one. This short chapter is the headline version; the full methods account, with safeguards and a part-by-part breakdown of who did what, is the appendix How this book was created.

Where it came from. The book grew out of Frédo's computational photography course at MIT. Two decades of lectures, slides, and problem sets are its backbone. That pre-existing material is large: roughly 305,000 words of lecture transcripts (automatic captions of the recorded lectures, captured by MIT's lecture-capture system and machine-transcribed), about 114,000 words of slide decks, and some 42,000 words of problem sets, or about 460,000 words of teaching, accumulated over years, before any of this writing began.

How it was written. It was then drafted with an AI collaborator (Claude), as a deliberate experiment in AI-assisted authoring: the outline, the figures, the prose, and even the book's own build tooling were co-developed with a model. The workflow keeps two living documents apart: an outline (an annotated specification of what the book says and shows) and the prose (how it reads). A compilation step turns the first into the second, the way a compiler turns source into a program. Crucially the arrow runs both ways: when the human author edits the prose, the change is triaged back to the right home so that re-compiling reproduces the author's corrections rather than forgetting them. Figures are not drawn by hand either; each is a small program that regenerates from source, so the figures and the prose can never quietly disagree.

How it is organized, and why no organization is perfect. Organizing a book like this is genuinely hard, and it is worth being candid about. The recurring dilemma is whether to lead with applications (the nails: denoising, panoramas, refocusing) or with fundamental techniques (the hammers: sampling, optimization, priors). Either order strands the other: lead with applications and you forward-reference machinery not yet built; lead with techniques and the reader wades through tools with no problem yet in hand. What one really wants is a causal order, each chapter depending only on what came before, but in a mature field that is almost impossible. The only organization that strictly respects causality is the real one, the chronology of discovery and invention, and that would preclude any clean conceptual organization at all, scattering related ideas across decades. And even chronological time is not as causal as we would like, because past inventions are often easier to understand and explain in hindsight, under framings that came later. So this book does what it can: an organization that tries to foreground both the big ideas and techniques and the applications that motivate them, leaning on generous cross-references where the two cannot be put in a line. But it is a compromise: things are never perfect when you try to fit a richly interconnected field into a single, sequential series of boxes.

Who did what. The plain division of labor is this. The AI was excellent at the things that are laborious but well-specified: drafting fluent prose from a tight, source-backed outline, writing and debugging figure code, and the mechanical bookkeeping (notation tables, cross-references, consistency sweeps) that no human enjoys. It was not trusted with judgment. A human chose the structure and the argument, decided what mattered and what to cut, caught the subtle errors that survive plausible-sounding prose, and owns every claim that remains.

A note on the numbers. It is tempting to tally "how much the human wrote," but that tally can be misleading. The prompts the author typed to steer the model come to about 69,000 words. The outline and the drafted chapters together come to about 1,090,000 words — but those are overwhelmingly model output, expanded from the prompts and grounded in the course corpus, not typed by hand. So the drafted prose is roughly 12× the typed direction, and the whole generated text about 16×, an output-to-input ratio, not a measure of authorship. (Generating it all, including drafts, revisions, and multi-pass AI review, came to about 100 million tokens of model usage, by Claude Code's own all-time meter: very roughly a few tens of kilowatt-hours of electricity, comparable to a few hundred hours of HD streaming; the appendix works that estimate, and its caveats, through.) (An earlier version of this book's accounting counted the outline as "human writing" and reported a much smaller 2.2× ratio; that was wrong, and the correction is itself a small lesson in being careful with self-flattering metrics.) The load-bearing human contribution is not the keystroke count. It is the curation: the structure, the choices, the corrections, and the sign-off on every page. That editorial judgment is exactly the scarce ingredient raw generated text lacks, and the reason we trust the result. The full process is documented in How this book was created, and the under-the-hood detail (prompts, prompt-engineering patterns, and the verifier suite) in its companion appendix, Under the hood: prompts, patterns, and verifiers.

Did writing it this way make me dumber? The obvious worry is that leaning on a model atrophies the very expertise it draws on, and I want to answer it plainly, in the first person, because my experience was the opposite. Writing this book with an AI made me learn more about my own field, not less. Two things happened that years of teaching the same material had not forced. First, at the micro scale, the relentless need to make every figure a runnable program and every claim survive a verifier dragged me into details I had waved past for two decades: what exactly happens when you run a Poisson solve, or a gradient blend, or a tone curve in gamma versus linear versus log space; where the half-pixel conventions of resampling actually bite; which "well-known" results are folklore. The model made it easy to run many small experiments quickly, and I ran hundreds I would never have bothered to set up by hand. Second, at the macro scale, having a collaborator that could hold the whole book at once let me think about the field as a structure: how the ideas actually relate, what the right order is, where the recurring lessons are, how the discipline has evolved from hand-built priors to learned and generative ones. Third, and least expected, the project pushed me outward: to decide what really belonged in the book I reached out to a great many people — researchers and engineers across academia and industry — to hear their read on the state of the field and, above all, on the concepts people should understand but too often don't. Those conversations reshaped the table of contents and taught me a great deal I would never have gone looking for on my own. That synthesis, the part I am proudest of, is not something the model produced; it is something the process let me produce, by taking the mechanical load off so I could spend my attention on judgment. The leverage numbers above measure how much text the collaboration generated; they do not measure the thing that actually changed, which is how much I came to understand. If anything, the danger of de-skilling is real precisely because the tool is so capable. The discipline that kept it from reducing expertise is the same one that makes the book trustworthy: never outsource the judgment, only the labor.