# Library Context

### Job this is for

Define and review the control packet around an agent workflow before the agent reads sources, uses tools, retries work, or proposes a side effect.

### When to use it

- a team is turning a repeated task into an agent workflow
- an agent needs accepted inputs and blocked inputs before running
- a proposed agent action needs preview and human approval
- retries, replanning, or irreversible actions need limits
- tool use must leave an audit-ready receipt

### Inputs needed

- workflow name, owner, and intended outcome
- accepted input examples and blocked input examples
- source rules and source owners
- proposed tools, allowed reads, allowed writes, and side effects
- approval owner and review threshold
- retry limits, stop conditions, and escalation route

### Expected output

- input contract and blocked-input decision
- source label set and source trace
- acceptance criteria and evidence rules
- action preview and approval packet
- retry budget and stop conditions
- permission receipt with what changed and why
- CRM-safe or public-safe summary when relevant

### What good looks like

- agents receive minimum necessary context and tools
- source trust is visible before claims or actions are used
- approval packets show the action, evidence, risk, and rollback path
- retry loops stop before irreversible actions or silent drift
- permission receipts can be audited after the run

### Operating steps

1. Identify the workflow owner and the business outcome before writing any agent instructions.
2. Classify inputs as accepted, needs redaction, or blocked.
3. Label every claim, source, and proposed action before relying on it.
4. Define done criteria, evidence rules, and blocked outputs before work starts.
5. Preview side effects before the agent writes, sends, deploys, publishes, or changes permissions.
6. Route review packets to the accountable human owner.
7. Record tool permission receipts and retry outcomes in the system of record.

### Operator run sheet

| Step | Owner              | Action                                        | Required input                                  | Data class   | Approved tool path        | Approval gate                        | System of record  | Done when                                  |
| ---- | ------------------ | --------------------------------------------- | ----------------------------------------------- | ------------ | ------------------------- | ------------------------------------ | ----------------- | ------------------------------------------ |
| 1    | Workflow Owner     | Define input contract and acceptance criteria | workflow owner, accepted inputs, blocked inputs | internal     | approved AI workflow tool | owner before first run               | workflow registry | input contract is approved                 |
| 2    | Security or AI Ops | Review source and tool boundaries             | source list, tool permissions, side effects     | confidential | approved review workspace | security when tools write externally | permission log    | boundaries are recorded                    |
| 3    | Human Approver     | Review action packet and retry budget         | action preview, evidence, rollback path         | confidential | review channel            | required before side effect          | approval record   | action is approved, rejected, or escalated |

This run sheet is the part a manager can operationalize. If the team cannot identify owner, data class, approval gate, and system of record, the workflow is not ready for agent use.