The pipeline that drafts a page is a chain of generative steps. One agent works out the strategy, another the structure, another the copy, another the design. Each is a model doing creative work with its own strict inputs and outputs. Something has to hold them together.
In an older system the answer would be a sequence of functions, each calling the next and passing along whatever it produced, or a chain of internal API calls doing the same across services. Either way, every step is wired directly to the step before it. Every step has to know the exact shape of what it is being handed, because there is nothing else guaranteeing it.
And in that older system there is usually a second layer between the steps, deterministic code that reshapes and repairs the objects as they pass, patching a missing field, coercing a value, fixing what the last step got wrong. That layer is exactly the one this platform spent a great deal of effort removing. The creative work is generative end to end. No deterministic function reaches in to correct what an agent produced. So the reshaping is gone. The question sharpens. If nothing repairs the objects between the steps, what keeps them sane?
The answer is a contract. Not a document but a running object. It is the deterministic container the generative pipeline runs inside.
A contract is a small state machine. It declares the steps the job moves through, carries the state that accumulates across them, and holds a status for where the job is. Every object that enters is checked against the shape the contract expects. Every move from one step to the next is checked against the steps the contract declares. An object of the wrong shape, or a move to a step that does not exist, does not get quietly patched. It throws. The violation is loud and immediate.
The important part is what the contract does not do. It never reshapes the content. It never repairs a value or fills a field or fixes what an agent wrote. It enforces the shape at entry and then holds the object, unchanged, for the next step to read. The agents keep their strict inputs and outputs. Their creativity runs free inside those boundaries. The contract is the container. It is not a corrector.
The contract is the container. It is not a corrector.
Because the shape is enforced at entry and guaranteed from there on, the steps stop needing to know each other. A step receives a state the contract has already vouched for, does its work, and hands back a state the contract will vouch for again. It does not know or care which path produced its input, only that the input is sane. The contract is the base that lets each step proceed agnostic of the last.
That is the difference between the contract and the old chain of serial functions. The serial chain couples every step to its neighbor. The contract decouples them. Each step talks to the contract and the contract talks to each step. No step has to know the entire pipeline.
This is also the step that had to come before durability, not after. You cannot safely move a workflow whose shape you cannot trust. Once the job runs inside a contract that is opinionated about its shape, it can leave the process it started in. It can be written down, handed off, and picked up somewhere else. The worker that picks it up knows the state is valid, because the contract is what guarantees it. Any worker, on any instance, regardless of the stack it runs on, can resume the job and stay correct.
That is what makes the contract the base for scale and durability both. The contract enforces the shape. A durable store, added on top of it, enforces the survival. One without the other is half a system. The contract without durability is correct but cannot outlive its process. Durability without the contract is persistent but has no guarantee that what it kept still makes sense. Together they are a workflow that is both correct and durable. The contract is the half that had to exist first.
There is a reading of this that seems to contradict what came before. This platform took pains to remove the deterministic code that shaped and repaired creative output. Now a deterministic object sits in the middle of the creative pipeline. The two do not conflict, because they act on different parts of the work. The code that was removed reached into the content and changed it. The contract never touches the content. It holds the objects and guarantees their shape. It leaves what they mean entirely alone. The container is deterministic. The contents are generative. The line between them is the whole design.
If you're interested in my work or Giant Context, contact me!