Sub topic 1
The draft-and-approve pipeline at a glance
Prerequisites
This chapter assumes you have three things:
- Basic experience prompting a large language model (LLM).
- Familiarity with a content workflow such as writing, editing, and publishing.
- Reading knowledge of simple Python. The one code example is short.
Why a pipeline
An AI model can produce a first draft in seconds. It cannot be held accountable for what the draft says. If a draft goes straight to readers, nobody has checked the facts, the tone, or the legal risk, and nobody owns the result.
A draft-and-approve pipeline fixes this. The model does the fast, cheap part (drafting). People do the part that needs judgment and responsibility (deciding what is published). Each later chapter covers one stage in detail. This chapter gives you the map.
The stages and who owns them
Content moves through five stages. Each has one owner, so every handoff has a named person or system.
| Stage | What happens | Owner |
|---|---|---|
| Brief | Audience, purpose, sources, and constraints are written down | Requester or editor |
| Draft | The model produces a first version from the brief | AI model, run by the requester |
| Check | Automated rules catch mechanical problems | Software |
| Review | A person judges the draft against a rubric | Reviewer (not the author) |
| Publish | Approved text goes live | Publisher, only after approval |
The "author" in this tutorial is the person who requested and submitted the draft. The model is a tool the author uses. It is never the approver.
The three rules the pipeline enforces
Every design choice in the following chapters serves one of these rules:
- A person approves, not the model. The approver must be someone other than the author. This is called separation of duties.
- Approval applies to exact text. If one word changes after approval, the approval no longer counts.
- Every step is recorded. You can later answer who changed what, and who approved it.
A first look in code
Here is the smallest version of the pipeline's core: a content item that can only be published after someone other than the author approves it.
from dataclasses import dataclass
@dataclass
class Item:
text: str
author: str
approved_by: str | None = None
def approve(self, reviewer):
if reviewer == self.author:
raise PermissionError("the author cannot approve their own item")
self.approved_by = reviewer
def publish(self):
if self.approved_by is None:
raise ValueError("not approved yet")
print("Published:", self.text)
item = Item(text="Spring sale starts Monday.", author="ben")
try:
item.approve("ben")
except PermissionError as err:
print("Blocked:", err)
item.approve("ana")
item.publish()This version is deliberately too simple. It has no states and does not check that the text is unchanged after approval. If someone edits item.text after ana approves, publish still succeeds. Later chapters add explicit states, a hash of the approved text, and a log.
Common mistakes at this stage
- Treating the model as a reviewer. A model checking its own draft is not an independent check.
- Leaving owners unnamed. If "the team" owns review, in practice nobody does.
- Adding gates everywhere. Too many approvals slow the work and push reviewers toward rubber-stamping. Later chapters show how to match effort to risk.
Exercise
A colleague proposes this shortcut: the author may approve their own AI-generated draft if the automated checks pass. Which of the three rules does this break, and what would you change?
Show answer
It breaks the first rule, that a person other than the author approves. Automated checks only catch mechanical problems such as banned phrases. They do not judge accuracy, tone, or risk. Keep the automated checks as a step before review, and require a different person to approve.