---
id: ai-layer
class: b2
sourced: 2026-07-12
source: "b2b-ux-patterns ch.13"
license: open
---
# Pass: the AI layer

**Inputs:** per intelligent capability — `intelligenceTime` (build-time | run-time), `aiWrites`, `blastRadius` (single-record | many-records | external-fanout), `reversible`, `outwardFacing`, `initiative` (invoked | suggested | initiated), `latency` (live | just-in-time | per-row | scheduled | ambient), `confidenceGateable`, `correctsHumanOrThirdParty`, `autonomousAgent`, `agentPrincipal`, `durableWait`, `copilotOutput` (inspectable-reversible | externally-committing), `accumulatedMemory`, `inputBoundaryTransduction`.
**Owns:** `archetypes`, `requiredStates`, `requiredMechanics`, `clarifications`.
**Output artifact:** for every AI capability, its decision-rights stance (who holds the write), the guardrail envelope (prevention + recovery + glass box), and the write-path bindings that connect it to the lifecycle, verbs, and access passes. Every AI pattern is a transfer of a slice of cognition from human to system; this pass governs the transfer.

## The rule

**Divide first by when the intelligence runs.** *Run-time* intelligence operates within a built system (fills fields, routes rows, drafts text, resolves) and transfers the operator's cognition. *Build-time* intelligence constructs the system itself (NL → tables, views, automations) and transfers the builder's cognition — its guardrail shape is **preview-the-generated-artifact and edit-before-commit**, never per-row confidence, and its compilation target must be inspectable (a node graph, a field list), never an opaque box.

**The three-actor write model is the spine, and the stance is set by blast radius and reversibility — not by model confidence alone.** *System proposes, human disposes* — output lands in a *proposed* state and waits for accept/edit/reject; the default for external, irreversible, or fan-out writes (a customer email, a bulk send). *System acts, human audits after* — the write commits, with the audit trail, rollback, and exception queue as the control; correct for internal, reversible, single-record writes. *System acts silently* — auto-classification, continuous re-enrichment; governance lives in configuration, sampling, and dashboards. The clean formulation: *AI proposes the signal, deterministic rules dispose the record.* Two axes cross the spine: **initiative** (invoked → suggested → initiated) separates next-best-action from anticipation; the **latency ladder** (live → just-in-time → per-row → scheduled → ambient) dictates the affordance — live cue cards streamed mid-call can never be a modal; scheduled jobs surface as a review queue on completion.

**Non-deterministic in, deterministic out.** Free-form material (dictated text, an email thread, a PDF, a receipt) is matched to the declared object model and lands as typed fields — the input-boundary transducer, "parse, don't type," applied at every scope (field, record, row-stream, table, ambient stream). Output generation is grounded in declared assets and post-filtered by deterministic rulebooks. Every AI write carries **origin = ai-generated** with provenance, rides the standard *proposed* state and approval verbs, and is **Logged with dual attribution** (the agent, and the human who accepted or the policy that authorized).

**Guardrails are one orthogonal layer, factored once.** *Prevention*: confidence gating with a numeric threshold where the domain is mature (high-confidence posts through, sub-threshold queues for review); **statistical-significance gating** where the system corrects a human or third-party claim (never assert on a small sample — the reputation guardrail, and the home of the house-knowledge corrective); simulation/eval gating before an agent version deploys. *Recovery*: the undo/rollback backstop under every agent action; the **escalation floor** — no serious autonomous agent ships without a mandatory hand-to-human boundary, and the handoff carries what was already tried so the human resumes mid-stream. *Glass box*: citations, the source anchor stored beside every transduced value, and the **AI-action audit log as a surface distinct from record edit history** (actor = AI, what changed, and what data informed it).

**The agent is a governed actor and the checkpoint is how the flow waits.** An agent principal gets its own identity in the directory, scoped least-privilege permissions, a human sponsor, and a lifecycle — never a borrowed human credential; its effective access is the intersection of its grants and its delegating subject's (see viewer-context). The **durable checkpoint** (axiom 21) — pause, persist, notify, resume — is the portable guardrail node: decision rights choose *when* the human enters; the checkpoint is *how* the flow waits, with state persisting across days and the notification carrying the evidence pack. Design against this primitive, not against inline blocking prompts. Chat is the **home surface** when its output is inspectable and reversible (conversational BI — expose the compiled query as the escape to determinism) and the **escape hatch** when output is externally committing (the human ratifies). Accumulated memory (system-auto-written, cross-session) is audited after and demands its own management surface and memory-provenance show-which. When an AI capability writes but its blast radius is undeclared, the decision-rights stance cannot be set: clarify.

```json decision-table
{"pass": "ai-layer", "rows": [
  {"when": {"intelligenceTime": "build-time"}, "then": {"requiredMechanics": {"mustInclude": ["preview-generated-artifact", "edit-before-commit", "inspectable-compilation-target"], "mustNotInclude": ["opaque-black-box", "per-row-confidence-on-build"]}}, "reason": "build-time-previews-the-artifact"},
  {"when": {"aiWrites": true, "blastRadius": "single-record", "reversible": true, "outwardFacing": false}, "then": {"requiredMechanics": {"mustInclude": ["ai-acts-human-audits-after", "audit-trail", "rollback-backstop", "exception-queue"]}}, "reason": "internal-reversible-single-record-acts"},
  {"when": {"outwardFacing": true}, "then": {"requiredMechanics": {"mustInclude": ["ai-proposes-human-disposes", "approval-verbs"], "mustNotInclude": ["ai-acts-silently"]}, "requiredStates": {"mustInclude": ["proposed"]}}, "reason": "external-facing-writes-propose"},
  {"when": {"blastRadius": "external-fanout"}, "then": {"requiredMechanics": {"mustInclude": ["ai-proposes-human-disposes", "approval-verbs"], "mustNotInclude": ["ai-acts-silently"]}, "requiredStates": {"mustInclude": ["proposed"]}}, "reason": "fan-out-writes-propose"},
  {"when": {"aiWrites": true, "reversible": false}, "then": {"requiredMechanics": {"mustInclude": ["ai-proposes-human-disposes"], "mustNotInclude": ["ai-acts-silently"]}, "requiredStates": {"mustInclude": ["proposed"]}}, "reason": "irreversible-writes-propose"},
  {"when": {"initiative": "initiated"}, "then": {"requiredMechanics": {"mustInclude": ["anticipation-system-initiated", "statistical-significance-gate"]}}, "reason": "system-initiated-needs-the-significance-gate-most"},
  {"when": {"initiative": "suggested"}, "then": {"requiredMechanics": {"mustInclude": ["next-best-action-same-recommendation-multi-surface"]}}, "reason": "suggested-is-next-best-action"},
  {"when": {"latency": "live"}, "then": {"requiredMechanics": {"mustInclude": ["streamed-cue-cards"], "mustNotInclude": ["live-output-in-a-modal"]}}, "reason": "sub-second-cannot-be-a-modal"},
  {"when": {"latency": "scheduled"}, "then": {"archetypes": {"mustInclude": ["queue"]}, "requiredMechanics": {"mustInclude": ["review-queue-on-completion", "evidence-pack"]}}, "reason": "scheduled-jobs-surface-a-review-queue"},
  {"when": {"confidenceGateable": true}, "then": {"requiredMechanics": {"mustInclude": ["confidence-threshold-gate", "sub-threshold-review-queue"]}}, "reason": "mature-domain-gates-on-confidence"},
  {"when": {"correctsHumanOrThirdParty": true}, "then": {"requiredMechanics": {"mustInclude": ["statistical-significance-gate", "house-knowledge-corrective"], "mustNotInclude": ["assert-on-small-sample"]}}, "reason": "reputation-guardrail-never-asserts-on-a-small-sample"},
  {"when": {"inputBoundaryTransduction": true}, "then": {"requiredMechanics": {"mustInclude": ["parse-dont-type-transducer", "source-anchor-per-value", "typed-fields-out"]}}, "reason": "non-deterministic-in-deterministic-out"},
  {"when": {"aiWrites": true}, "then": {"requiredMechanics": {"mustInclude": ["origin-ai-generated-provenance", "dual-attribution-logged", "ai-action-audit-log-distinct"]}}, "reason": "ai-writes-carry-provenance-and-dual-attribution"},
  {"when": {"autonomousAgent": true}, "then": {"requiredMechanics": {"mustInclude": ["escalation-floor-hand-to-human", "handoff-carries-context", "supervisor-layer", "undo-rollback-backstop"], "mustNotInclude": ["no-escalation-boundary"]}}, "reason": "no-autonomous-agent-without-an-escalation-floor"},
  {"when": {"agentPrincipal": true}, "then": {"requiredMechanics": {"mustInclude": ["agent-own-directory-identity", "scoped-least-privilege", "human-sponsor", "delegated-subject-intersection"], "mustNotInclude": ["borrowed-human-credential"]}}, "reason": "agent-is-a-governed-principal"},
  {"when": {"durableWait": true}, "then": {"requiredMechanics": {"mustInclude": ["durable-checkpoint-pause-persist-notify-resume", "notification-carries-evidence-pack"], "mustNotInclude": ["inline-blocking-prompt"]}}, "reason": "design-against-the-checkpoint-primitive"},
  {"when": {"copilotOutput": "inspectable-reversible"}, "then": {"requiredMechanics": {"mustInclude": ["chat-as-home-surface", "expose-compiled-query", "promote-answer-to-artifact"]}}, "reason": "inspectable-reversible-output-lives-in-chat"},
  {"when": {"copilotOutput": "externally-committing"}, "then": {"requiredMechanics": {"mustInclude": ["chat-as-escape-hatch", "human-ratifies-before-commit", "propose-then-confirm"], "mustNotInclude": ["chat-commits-externally-unratified"]}}, "reason": "externally-committing-output-is-ratified"},
  {"when": {"accumulatedMemory": true}, "then": {"requiredMechanics": {"mustInclude": ["memory-management-surface", "memory-provenance-show-which", "identity-scoped-memory"]}}, "reason": "auto-written-memory-is-audited-after"},
  {"when": {"aiWrites": true, "blastRadius": "__absent__"}, "then": {"clarifications": ["ai-write-blast-radius-unspecified"]}, "reason": "decision-rights-stance-needs-blast-radius"}
]}
```
