What is a workbook

A workbook is the woven artifact — the single, self-contained thing you ship and run. You author a folder of .work files; the work CLI weaves that folder into one workbook, and a Nexus runs it (or a browser opens it). The folder is the source; the workbook is the product.

Source vs. workbook

It's worth keeping the two apart, because they're easy to blur:

The relationship is the familiar one between source and build: you edit a tree of files; a build step folds them into the thing you actually ship. Here the build step is the weave, and its output is the workbook.

How it's woven

You never assemble a workbook by hand — the CLI does it from the source folder:

work weave <dir> <out>   # fold the .work tree into one workbook
work check <dir>         # resolve refs + audit what each block may do
work dev <dir>           # watch the folder and re-weave as you edit

work weave reads the whole tree, resolves the links between files, and emits a single artifact. work dev does the same continuously, re-weaving on every save and hot-swapping the result into a running Nexus, so the live workbook tracks your edits.

That artifact is HTML — but HTML here is purely a build output, the format the weave emits because it runs everywhere. You don't author or configure it and you never hand-write it. You write .work; the weave produces the workbook.

What you put in the source

Everything you write in the source .work files falls into one of four lanes — you'll meet them properly in Anatomy of a .work file:

One file can hold all four. That's the point — the thing people see, the code that makes it work, and the data it stands on don't live in three repositories. They sit together in the source, and the weave carries them into one workbook.

Why a single artifact

Because a workbook is one woven thing, it moves the way a finished document moves: you deploy it to a Nexus, open it in a browser, or hand it to someone — and they get the whole piece of software at once, interface and logic and data shape together. The source stays legible for authoring and review; the workbook is the compiled result that actually runs.

Kits and apps

Most workbooks are one of two things. A kit is meant to be imported and composed by other workbooks — a shared piece other things build on. An app is the leaf you launch — the thing with an interface you actually open. A workbook can be both: an app that also exports a kit for the next one to use.

You don't have to decide this up front. Write a .work file, weave the folder, and you have a workbook — head to What is a .work file to see what goes in the source.