graphs.sgit.aithe booksCreating a Book Using Agentic Workflowsthe graph

The book as a graph

Creating a Book Using Agentic Workflows v0.2.0, decomposed all the way to the word and provably put back together. Six levels: book → chapter → section → block → sentence → word. Built by admin/build/gen_bookgraph.py from the chapter markdown, which stays the authored source.

Why this exists, and it is not because a graph is interesting. Brief 42 asks for the book’s opening to change: a new first part, the history moved behind it. Doing that by hand is exactly the edit the founder says broke his earlier books — “you almost start to be locked by the first version of the content, because making changes becomes quite painful.” Doing it as a transformation on this graph, with a gate proving every chapter that was not meant to move is byte-identical, is the thing a word processor cannot do. Every chapter below rebuilt byte-identical on this build. That is the claim the restructure rests on.
#ChapterSectionsBlocksWordsFormsIdentitiesGraph
01Creating a Book Using Agentic Workflows7321,18344139json
021 · The loop7381,68962745json
032 · The first book, and the pivot that saved the second6421,75759348json
043 · Briefs as the contract8511,82962459json
054 · Gates buy speed8481,92265556json
065 · From a page to an instrument8561,55855464json
076 · Two agents, one repository7461,54954953json
087 · The failures, lovingly15702,42775985json
098 · Reviewing out loud8511,61955959json
109 · The experiments7692,23870976json
1110 · The founder's craft8451,42454853json
1211 · The playbook15841,79562499json
1312 · What it costs, and where it loses16431,63657359json
14Appendix A · One brief, annotated13572,35163270json
15Appendix B · The chronology817875425json
16Appendix C · The harness164160729557json
17Colophon8321,33151240json
The book16582227,002index.json

What each chapter folder holds

FileWhat it is
index.jsonthe chapter’s section skeleton, counts and shard pointers
sec-NN.jsonone shard per section: its blocks, sentences and word instances
fmt.jsonthe formatting graph — heading lines, gaps and raw markdown per block. This is the half that makes the rebuild possible; the semantic shards are provably derivable from it
words.jsonone node per distinct form, with every instance
tokens.jsonthe token analysis: classes, stem families, co-occurrence
ids.jsonthe identity ledger — short opaque uids carried across edits, so a cross-reference survives a rewrite
Sharded per chapter, on purpose. Brief 43 flagged size as a strain before any code was written, and it was right: this graph is 3,646,054 bytes against 552KB for the single pilot document. Opening one chapter fetches one chapter. The estimate made before building was ~4MB; the measured figure is 3.6MB.
What this does not yet do. There is no explorer here — this page is a table, not the instrument brief 43 asks for (“the visualisation of that parser… is more important than the actual output”). That is activity A5. The five reading levels are A4, and the restructure this all exists to enable is A6. The plan tracks all seven.